Remote virtualenv Python interpreter

Hi. I can't seem to get my PyCharm to properly use an interpreter on a remote machine. I get the following message:
/path/to/my/virtualenv/bin/python: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No such file or directory

When I try to add the same interpreter locally on that machine, everything works fine. Has anyone come across this problem? How can I resolve it?

I don't have root access on the remote machine. When I created the virtualenv on the machine, I had to add python as a module first with this command:
http://linux.die.net/man/1/module
I don't know if this is relevant, but just in case...
8 comments
So, I've managed to import my remote virtualenv, I had to add an environment variable to my ~/.cshrc file:
setenv LD_LIBRARY_PATH /app/python/2.7.1/LMWP3/lib

But now I can't enable Django support for the project. In Settings > Django Support it asks me to enter my local path to the project (which is on Windows), but when I try to run the project, it passes these parameters to the remote machine (which is a Linux machine). These parameters are obviously not the same. How can I resolve this problem?
0
Hi, could you please create an issue regarding the problem: http://youtrack.jetbrains.com/issues/PY
Describe there please which path do you enter and which parameters are being passed.
0
It seems it already exists. This is the problem:
http://youtrack.jetbrains.com/issue/PY-9792

There it says you won't fix this, but it would be really helpful if you did. I'm supposed to run my Django app on a remote server because it communicates and fetches data from a REST service available there. Because of this I can't run or debug it locally on my computer, these services are unreachable from it. But that doesn't mean I can't code locally. The remote server does have an X server running, but it's painfully slow to run PyCharm there.

If I have the same type of OS locally and remotely (for example, both Linuxes) and if I check out the project in the exact same directory structure here and there, everything works fine because in Django settings I'm setting the local values, but when running the project, they will be used on the remote server.

I'm talking about the settings in Settings > Project Settings > Django Support. When I first saw them, I thought this would solve my problem. But my local computer is running Windows so it really doesn't. My temporary fix is that I've created a virtual machine running Linux on my computer and I've set up the exact same directory structure as on the server and this works relatively ok now. But it's not as responsive as it would be if I were to run PyCharm on Windows.
0
Just an additional note. For this to work, the local and remote codebase have to be synced. Because when you run the debugger and are stepping through code, the editor will display local code, but the debugger will go through remote code. I've also solved this quite elegantly. In the run configuration, in the before launch section I've put a rsync script which syncs my remote codebase with local changes and this works quite well.

The only thing which remains is specifying remote Django parameters separately so the directory structure needn't be the same. That would be resolved with the linked issue.
0
But it would be really helpful if you did. I'm supposed to run my Django app on a remote server because it communicates and fetches data from a REST service available there. Because of this I can't run or debug it locally on my computer, these services are unreachable from it. But that doesn't mean I can't code locally. The remote server does have an X server running, but it's painfully slow to run PyCharm there.

If I have the same type of OS locally and remotely (for example, both Linuxes) and if I check out the project in the exact same directory structure here and there, everything works fine because in Django settings I'm setting the local values, but when running the project, they will be used on the remote server
0

Any updates on this issue? Currently trying to configure a remote interpreter for my PyCharm Project (pure python) and am getting virtually the same error: `/path/to/my/virtualenv/bin/python: error while loading shared libraries: libpython3.5m.so.1.0: cannot open shared object file: No such file or directory`

0

+1.  Remoting from one virtual environment on a Mac to another on Linux:

File "/home/ubuntu/Development/chroma_env/src/chroma/chroma/generator/g4gen.py", line 1, in <module>
from chroma.generator.mute import *
ImportError: libboost_python.so.1.64.0: cannot open shared object file: No such file or directory

Both of the virtual_envs work fine locally

0

+1 to this. Since you can setup a remote virtual env, enabling framework support for remote configurations seems to be the next logical step. Not just for runservers and such (which is easy to do manually), but for code completion and checking.

0

Please sign in to leave a comment.