##// END OF EJS Templates
util: rewrite pycompat imports to make pyflakes always happy...
Yuya Nishihara -
r30471:00c9ac4c default
parent child Browse files
Show More
@@ -48,25 +48,17 b' from . import ('
48 pycompat,
48 pycompat,
49 )
49 )
50
50
51 for attr in (
51 empty = pycompat.empty
52 'empty',
52 httplib = pycompat.httplib
53 'httplib',
53 httpserver = pycompat.httpserver
54 'httpserver',
54 pickle = pycompat.pickle
55 'pickle',
55 queue = pycompat.queue
56 'queue',
56 socketserver = pycompat.socketserver
57 'urlerr',
57 stringio = pycompat.stringio
58 'urlparse',
58 urlerr = pycompat.urlerr
59 # we do import urlreq, but we do it outside the loop
59 urlparse = pycompat.urlparse
60 #'urlreq',
61 'stringio',
62 'socketserver',
63 'xmlrpclib',
64 ):
65 a = pycompat.sysstr(attr)
66 globals()[a] = getattr(pycompat, a)
67
68 # This line is to make pyflakes happy:
69 urlreq = pycompat.urlreq
60 urlreq = pycompat.urlreq
61 xmlrpclib = pycompat.xmlrpclib
70
62
71 if os.name == 'nt':
63 if os.name == 'nt':
72 from . import windows as platform
64 from . import windows as platform
General Comments 0
You need to be logged in to leave comments. Login now