{"action":"created","issue":{"url":"https://api.github.com/repos/neovim/python-client/issues/55","labels_url":"https://api.github.com/repos/neovim/python-client/issues/55/labels{/name}","comments_url":"https://api.github.com/repos/neovim/python-client/issues/55/comments","events_url":"https://api.github.com/repos/neovim/python-client/issues/55/events","html_url":"https://github.com/neovim/python-client/issues/55","id":47792931,"number":55,"title":"python-client imports from current working directory","user":{"login":"btipling","id":249641,"avatar_url":"https://avatars.githubusercontent.com/u/249641?v=3","gravatar_id":"","url":"https://api.github.com/users/btipling","html_url":"https://github.com/btipling","followers_url":"https://api.github.com/users/btipling/followers","following_url":"https://api.github.com/users/btipling/following{/other_user}","gists_url":"https://api.github.com/users/btipling/gists{/gist_id}","starred_url":"https://api.github.com/users/btipling/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btipling/subscriptions","organizations_url":"https://api.github.com/users/btipling/orgs","repos_url":"https://api.github.com/users/btipling/repos","events_url":"https://api.github.com/users/btipling/events{/privacy}","received_events_url":"https://api.github.com/users/btipling/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2014-11-05T02:32:35Z","updated_at":"2015-09-14T14:05:04Z","closed_at":null,"body":"Say I have a plugin at `~/.nvim/pythonx/neovim_thing.py` and it imports  `~/.nvim/pythonx/foo.py`. Assuming my current working directory is `~/dev/foo/`, if I start nvim and there happens to be a `~/dev/foo/foo.py` there this file is imported by my plugin instead of `~/.nvim/pythonx/foo.py` which breaks the plugin. "},"comment":{"url":"https://api.github.com/repos/neovim/python-client/issues/comments/140085791","html_url":"https://github.com/neovim/python-client/issues/55#issuecomment-140085791","issue_url":"https://api.github.com/repos/neovim/python-client/issues/55","id":140085791,"user":{"login":"yagebu","id":2482259,"avatar_url":"https://avatars.githubusercontent.com/u/2482259?v=3","gravatar_id":"","url":"https://api.github.com/users/yagebu","html_url":"https://github.com/yagebu","followers_url":"https://api.github.com/users/yagebu/followers","following_url":"https://api.github.com/users/yagebu/following{/other_user}","gists_url":"https://api.github.com/users/yagebu/gists{/gist_id}","starred_url":"https://api.github.com/users/yagebu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yagebu/subscriptions","organizations_url":"https://api.github.com/users/yagebu/orgs","repos_url":"https://api.github.com/users/yagebu/repos","events_url":"https://api.github.com/users/yagebu/events{/privacy}","received_events_url":"https://api.github.com/users/yagebu/received_events","type":"User","site_admin":false},"created_at":"2015-09-14T14:05:03Z","updated_at":"2015-09-14T14:05:03Z","body":"I only discovered this bug when running Nvim in a directory with a file `json.py` in it. In my setup, this is imported by YouCompleteMe. With neovim/neovim#3331, it correctly imports the system `json` module.\r\n\r\n@justinmk in that line, only the plugin is loaded that was found 3 lines above. There it is actually made enforced that only the plugin path is searched (by giving it as an explicit argument to `imp.find_module`). There's only a problem if said plugin imports other Python modules. For these `sys.path` will be searched, which shouldn't contain the current working directory with the change in https://github.com/neovim/neovim/pull/3331/files#diff-56c8fc368678358892f215c76bd2178cR200. So my understanding is that neovim/neovim#3331 fixes this (at least it seems to do in my case :D )"}}