Skip to content

Commit 66c23ea

Browse files
committed
Do not fall back on python 2 configparser
1 parent e6ef2e3 commit 66c23ea

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

python/lsst/sconsUtils/state.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
import os
1717
import re
1818
import shlex
19+
from configparser import ConfigParser
1920

2021
import SCons.Conftest
2122
import SCons.Script
@@ -623,12 +624,6 @@ def _saveState():
623624
if env.GetOption("clean"):
624625
return
625626

626-
# Python 2 uses ConfigParser, Python 3 uses configparser
627-
try:
628-
from configparser import ConfigParser
629-
except ImportError:
630-
from ConfigParser import ConfigParser
631-
632627
config = ConfigParser()
633628
config.add_section("Build")
634629
config.set("Build", "cc", env.whichCc)

0 commit comments

Comments
 (0)