diff --git a/reorder_python_imports.py b/reorder_python_imports.py index 991ad75..f52cc08 100644 --- a/reorder_python_imports.py +++ b/reorder_python_imports.py @@ -564,7 +564,7 @@ def _fix_file( 'six.moves.BaseHTTPServer=http.server', 'six.moves.CGIHTTPServer=http.server', 'six.moves.SimpleHTTPServer=http.server', - 'six.moves._dummy_thread=_dummy_thread', + 'six.moves._dummy_thread=_thread', 'six.moves._thread=_thread', 'six.moves.builtins=builtins', 'six.moves.cPickle=pickle', @@ -609,6 +609,7 @@ def _fix_file( 'six.moves.urllib_error=urllib.error', 'six.moves.urllib_parse=urllib.parse', 'six.moves.urllib_robotparser=urllib.robotparser', + 'six.moves.winreg=_winreg', 'six.moves.xmlrpc_client=xmlrpc.client', 'six.moves.xmlrpc_server=xmlrpc.server', 'six.moves=collections:UserDict', diff --git a/testing/generate-six-info b/testing/generate-six-info index eabcf07..a5785a8 100755 --- a/testing/generate-six-info +++ b/testing/generate-six-info @@ -37,6 +37,9 @@ def main() -> int: for submod in ('error', 'parse', 'request', 'response', 'robotparser') ] + # six only exports this on windows + renames.append('six.moves.winreg=_winreg') + # not in six.moves for some reason renames.extend(( 'six=functools:wraps',