{"action":"opened","issue":{"url":"https://api.github.com/repos/PyCQA/pylint/issues/965","repository_url":"https://api.github.com/repos/PyCQA/pylint","labels_url":"https://api.github.com/repos/PyCQA/pylint/issues/965/labels{/name}","comments_url":"https://api.github.com/repos/PyCQA/pylint/issues/965/comments","events_url":"https://api.github.com/repos/PyCQA/pylint/issues/965/events","html_url":"https://github.com/PyCQA/pylint/issues/965","id":163034793,"number":965,"title":"wrong-import-position error generated on PEP8 compliant imports w/ dunders","user":{"login":"openfly","id":645837,"avatar_url":"https://avatars.githubusercontent.com/u/645837?v=3","gravatar_id":"","url":"https://api.github.com/users/openfly","html_url":"https://github.com/openfly","followers_url":"https://api.github.com/users/openfly/followers","following_url":"https://api.github.com/users/openfly/following{/other_user}","gists_url":"https://api.github.com/users/openfly/gists{/gist_id}","starred_url":"https://api.github.com/users/openfly/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openfly/subscriptions","organizations_url":"https://api.github.com/users/openfly/orgs","repos_url":"https://api.github.com/users/openfly/repos","events_url":"https://api.github.com/users/openfly/events{/privacy}","received_events_url":"https://api.github.com/users/openfly/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-06-29T21:49:00Z","updated_at":"2016-06-29T21:49:00Z","closed_at":null,"body":"### Steps to reproduce\r\n1. create python script like: https://gist.github.com/openfly/50ddd090a5ee8913dee945f932fe1906\r\n2. run pylint --output-format=colorized --max-line-length=120 --disable=too-few-public-methods,no-member,too-many-ancestors example.py\r\n3. see that there are errors:\r\nC: 10, 0: Import \"import sys\" should be placed at the top of the module (wrong-import-position)\r\nC: 11, 0: Import \"import getopt\" should be placed at the top of the module (wrong-import-position)\r\nC: 12, 0: Import \"import traceback\" should be placed at the top of the module (wrong-import-position)\r\n\r\n### Current behavior\r\nBasically the dunder entries in the example.py above the imports are generating a hit on wrong-import-position\r\n\r\n### Expected behavior\r\naccording to : https://www.python.org/dev/peps/pep-0008/#module-level-dunder-names\r\nthis isn't actually a wrong position.  this is PEP8 compatible.\r\n\r\n### pylint --version output\r\npylint --version\r\nNo config file found, using default configuration\r\npylint 1.5.6,\r\nastroid 1.4.6\r\nPython 2.7.11 (default, Jan 22 2016, 08:28:37)\r\n[GCC 4.2.1 Compatible Apple LLVM 7.0.2 (clang-700.1.81)]\r\n"}}
{"actor":{"display_login":"openfly"}}