# HG changeset patch # User Anton Shestakov # Date 1550066189 -28800 # Node ID 8b91088944caf40a057c53c962717d7092a8f262 # Parent 51b0185a0e7b328ecbeda6b4d0cba5c95434e8a3 obsexchange: avoid importing io/StringIO module with a different name Since we're not interested in the whole module, let's shorten the imports and aviod the lint warnings. Otherwise pep8-naming complains: - import io as StringIO: N812 lowercase imported as non lowercase - import StringIO as io: N813 camelcase imported as lowercase diff -r 51b0185a0e7b -r 8b91088944ca hgext3rd/evolve/obsexchange.py --- a/hgext3rd/evolve/obsexchange.py Wed Feb 13 21:56:05 2019 +0800 +++ b/hgext3rd/evolve/obsexchange.py Wed Feb 13 21:56:29 2019 +0800 @@ -8,11 +8,9 @@ from __future__ import absolute_import try: - import StringIO as io - StringIO = io.StringIO + from StringIO import StringIO except ImportError: - import io - StringIO = io.StringIO + from io import StringIO from mercurial import ( bundle2,