JulianEberius / SublimePythonIDE

ST3 only: A rewrite of SublimeRope for ST3, uses the Rope library to add python completions and refactoring to ST3
GNU General Public License v2.0
267 stars 38 forks source link

Python interpreter path detection doesn't work well on non-unix environment #84

Open merlynmg opened 8 years ago

merlynmg commented 8 years ago

I'm on Windows 10. The detection of fall through/error detection mechanism doesn't work well. Falling through on empty is fine, but IMO it should also fall through on error.

In my case, here's my settings:

There are some work around options, but they seem less than optimal.

If I set C:\\Python27\\python.exe in the project config, everything is okay. However this is, as far as I'm concerned, a system setting for me, and not a project setting.

I have virtual environments set up, using a user-level ~/.virtualenvs directory rather than one under my project's path, though as you can see it is not detecting it. Not sure how to get SublimePythonIDE to find that, or if the path differences would pan out (C:\\Python27\python.exe vs /c/Python27/python.exe).

Edit: I figured out why it isn't detecting my venv. I'm nesting multiple projects under the same source control, with different virtual environments for each, and the venv detection is project folder name based. I can't figure out a reasonable way this could be implemented to work, yet still keep my sublime text project at the root directory. I am guessing a most other projects probably won't have this problem.

Fortunately I have a patch that might make any workarounds unnecessary, and also won't require me to get venv detection working for this project :)