jayvdb created this task. jayvdb added subscribers: jayvdb, valhallasw, XZise, Xqt. jayvdb added a project: pywikibot-core. Restricted Application added subscribers: Aklapper, pywikipedia-bugs.
TASK DESCRIPTION There is a new pep8 rule which was added in July 2014, and will be released soon. If it is deployed on the build machines, it would prevent any other changes from being merged.
The rule is
E402 module level import not at top of file, and looks like
pywikibot/data/api.py:10:1: E402 module level import not at top of file
https://github.com/jcrocholl/pep8/issues/264 https://github.com/jcrocholl/pep8/commit/1ee296bca0fa611d3dbe87c5c5c8009e448...
pywikibot has several imports not at the top of the file, due to cyclic dependencies, but that number is small compared to the number of these errors caused by __version__ appearing before the imports.
Note that pep8 also needed to change their code to relocate __version__ to appear below imports.
https://github.com/jcrocholl/pep8/commit/373e0ac1138f0e24422b5e2e78f02ed0557...
There is a broader issue of the usefulness of these __version__ variables for every file, and there is some $Id$ voodoo in bot.py:740-745 which we should revisit.
TASK DETAIL https://phabricator.wikimedia.org/T87409
REPLY HANDLER ACTIONS Reply to comment or attach files, or !close, !claim, !unsubscribe or !assign <username>.
EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: jayvdb Cc: Xqt, XZise, valhallasw, jayvdb, Aklapper, pywikipedia-bugs