-
-
Notifications
You must be signed in to change notification settings - Fork 47
Optionally add Sage to native Windows PATH, along with related environment variables #13
Comments
I'm not sure what you mean that it would achieve, if I add those to my path PyCharm still won't recognise Sage's python as correct. But it sounds like a step in the right direction, makes sense that other programs should need to know there the executables are.
|
The error you posted here is because you gave PyCharm a path to a Cygwin symlink (which to native Windows/shell just looks like a normal file that is not a valid executable) hence the error. But even if you give an absolute path to the Python executable that is not sufficient--you need Sage's bin dir to be added to the system |
@embray Do you think you'll be adding this soon? |
@NavyAdmiral Are you also trying to find a proper IDE for Sage on Windows? Actually this issue was raised while trying to get Sage to work using PyCharm, but when part of that worked I found that it was (at that time, at least) much too slow: it could take up to 30 seconds for Sage to start and run your code. See the sage-devel google group, in order to run Sage code you have to start up the Sage shell, then convert the code to Python and then run that Python code I think. Something like that. The next thing I'd try if I had any hopes of succeeding is trying to use vim for windows, as supposedly there are people who have Sage working with vim on linux so it might work better than PyCharm. Anyway, I think this issue lost relevance by now? @embray |
I want to get Sage Intellisense (suggestions, autocompletion, ...) in VSCode. |
Yup, that's what I meant. Would be great if you could let people know if you succeeded, when you do :) (you could answer for example on stackoverflow or ask.sagemath.org. ) |
The link I gave above for how to do this in PyCharm is pretty broadly applicable. At the very least you need to add the correct |
In playing around with the problem in #12, one thing that I found might be useful would be to add the correct entries to the Windows
PATH
environment variable for executables installed in Sage to work directly on Windows.For example, if you try to add Sage's Python interpreter to PyCharm it breaks when PyCharm tries to run it, because the path to the Cygwin DLL (e.g.
C:\Program Files\SageMath 8.1\runtime\bin
), at the very least, must be onPATH
for the executable to even work. If that at a minimum is set, possibly along with the Windows path to$SAGE_LOCAL\bin
, then most executables installed in$SAGE_LOCAL
can work on the system outside the Sage shell (that is, they can at least execute--in order for them to work correctly additional environment variables may need to be set, such as$SAGE_ROOT
, etc.@PHPirates
The text was updated successfully, but these errors were encountered: