1

Background: I am trying to run a windows-installed version of python from within cygwin, rather than the cygwin version (some packages I am using prefer the non-cygwin version). The following post got me up and running: Using Windows Python from Cygwin. However, I am now having an issue.

Problem: The PYTHONPATH variable does not seem to be working for me. I try "import module1" when I am using python in an arbitrary directory. module1 is located here: c:\cygwin\home\mcsefl\testFolder\module1.py. And my PYTHONPATH variable is set in my .bashrc file in the following way: "export PYTHONPATH=$PYTHONPATH:/home/mcsefl/testFolder". However I still get a "No module named..." error.

Alternate tries: Since I am running the Windows Python, I thought perhaps python did not care about the cygwin environment variables (not sure if this is true..?) So, I also tried to set the windows PYTHONPATH env variable in the control panel of windows with no luck as well.

Thanks in advance

4

1 回答 1

0

我删除了 .bashrc 文件中试图设置 PYTHONPATH 变量并让它由 Windows 设置的行。这可以纠正问题。

旁注:这个问题的标题用词不当,因为我重新阅读了它。我的问题在没有解决整个问题的情况下得到了解决

于 2013-12-19T20:50:01.143 回答