Skip to content

Commit 2da65a7

Browse files
committed
chore: drop leftover Python 2.7 import aliases from setup.py
1 parent 3fa60fd commit 2da65a7

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

setup.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,7 @@
3636
from distutils.ccompiler import get_default_compiler
3737
from distutils.errors import CompileError
3838

39-
try:
40-
import configparser
41-
except ImportError:
42-
import ConfigParser as configparser
39+
import configparser
4340

4441
# Take a look at https://www.python.org/dev/peps/pep-0440/
4542
# for a consistent versioning pattern.
@@ -161,10 +158,7 @@ def autodetect_pg_config_path_windows(self):
161158
return None
162159

163160
def _get_pg_config_from_registry(self):
164-
try:
165-
import winreg
166-
except ImportError:
167-
import _winreg as winreg
161+
import winreg
168162

169163
reg = winreg.ConnectRegistry(None, winreg.HKEY_LOCAL_MACHINE)
170164
try:

0 commit comments

Comments
 (0)