PyCharm does not show modules in site-package in a remote virtual env project
已回答
While I can remote debug a dango project successfully, PyCharm does not show modules in site-package in the remote virtual env.
( because I cannot see source code, "remote debug" above means just I can "Run"->"Debug" from menu. )
* modules such as django are successfully installed in the virtual env and can run web server.
请先登录再写评论。
Hi yukilab,
Thank you for contacting PyCharm support.
Is it `Settings/Preferences | Project | Project Interpreter` what you are looking for? Here you are able to view all the packages installed to your remote interpreter.
Please correct me if I have misunderstood.
Looking forward to your reply.
Kind regards,
Sergey
https://www.jetbrains.com
The Drive to Develop
Hi Sergey, no.
What I'm pointing is Project Explorer -> External Libraries as attached image. In typical projects I saw remote libraries under site-package but this time I don't see even site-package itself.
Remote packages installed in remote virtual environment can still be seen in 'Settings/Preferences | Project | Project Interpreter' UI though.
Does directory exist on your remote machine for this interpreter?
It could be that this directory doesn't exist and thus is not shown in PyCharm.
You could also browse remote host (Tools | Deployment | Browse Remote Host).
Kind regards,
Sergey
https://www.jetbrains.com
The Drive to Develop
Yes. Modules exist in the site-package directory and can be browsed with Tools | Deployment | Browse Remote Host
Oh, I see.
What is your PyCharm version?
Could you please check latest EAP build? https://www.jetbrains.com/pycharm/nextversion/ There're a bunch of related fixes in it.
Kind regards,
Sergey
https://www.jetbrains.com
The Drive to Develop
Thank you for prompt support, Sergey,
I was using 2018.2.4. I have updated PyCharm following given link and now it is 2018.3 EAP. Issue remains same though even re-assigned / indexed project interpreter.
1) Please add the following lines to Debug Log Settings as described here https://youtrack.jetbrains.com/issue/PY-22254#focus=streamItem-27-3055432-0-0. Then reproduce the problem and attach your idea.log (Help | Show Log in...).
2) What is OS of your server?
Kind regards,
Sergey
https://www.jetbrains.com
The Drive to Develop
Sergey,
1) Please find log at https://gist.github.com/yukilab2/f5d6f1f7460afb829dee77249439dc31. (this site does not allow attaching files other than jpeg, gif or png)
2) local server is macos; remote server is ubuntu 16.04LTS.
BR
Tha
The link doesn't seam to be working for me, sorry. Please upload it zipped to https://uploads.services.jetbrains.com/ with some different name and provide the name of the zip file so we can find it.
Thank you!
Kind regards,
Sergey
https://www.jetbrains.com
The Drive to Develop
Nope, was some glitch, I was able to access it with your link.
Thanks!
Hi yukilab, thank you for the logs, I created a ticket in our bug tracker for a responsible developer to investigate https://youtrack.jetbrains.com/issue/PY-32035 Please follow it for updates and feel free to remove the gist.
thank you Pavel and Sergey. I follow the ticket.
hello Sergey Karpov
I really appreciate if you can help me to configure ssh remote on pycharm professional, I have followed the instruction on the website, but I still face a lot of problem
Setup tool is not found, so I cannot load any package such as tensorflow from server (hpc).
Could you show me how to load other packages such as tensorflow, pytorch when running remotely?
I really need you help
I have the same problem. When I point to a remote interpreter via SSH that happens to be in a virtualenv, it doesn't recognize the virtualenv. It just sees the packages installed on the server globally.
It would be great to have it recognize the virtualenv.
Hi Scott, which path to the python executable did you select while creating the remote interpreter? Could you create a ticket in PyCharm's bug tracker please?
I've met the same problem with Scott Smith. Is there any update on this issue?
The installed packages are properly listed under the python interpreter setting view but seem not recognized by the IDE.
I've reindexed multiple times and tried to set the PATH manually, but the External Libraries were still undetected.
Since the report link above is broken and I searched and found no bug that is the same there, I've submitted a bug report.
I have similar problem - the additional packages are installed in externall folder - site-packages under .local folder on my home directory on remote. However, the path to interpreter is global path and does not contain additional packages. How can I add this external folder to the pycharm interpreter?
Directories with site packages could be added manually. For PyCharm Professional 2021.3 on Mac go PyCharm -> Preferences -> Project -> Python Interpreter, press the gear button -> Show All..., select your interpreter and press "Show paths for selected interpreter" button and add path to site packages folder.
In my case it also worked with writing full path to "Python interpreter path" in Python Interpreter settings.