Shonosuke
Shonosuke

Reputation: 123

IntelliJ IDEA - how to map remote PYTHONPATH to local environment?

I'm using python remote interpreter in IntelliJ(13.1), and using "composes" modules which are installed on server.

By importing the module like follwing, I can use the module without any problem, but I get warn "No module named composes".

import composes

And I can't get the auto complete of the module in editor.

Do I need to map the remote PYTHONPATH to local?

If so, please tell me how to do that.

Upvotes: 2

Views: 1299

Answers (1)

fatiherdem
fatiherdem

Reputation: 1223

I found some documentation for this:

http://www.jetbrains.com/pycharm/quickstart/configuring_interpreter.html

I think best way is remote SSH interpreter. Check this out.

Edit: But don't forget. If you choose remote interpreter, you can't use your local modules.

Edit2:

1) Add deployment server from Tool->Deployment->Configuration

enter image description here

2) Add remote interpreter from File->Settings->Project Interpreter->Add remote And select the Deployment Configuration for FTP connection and can send to server your local files

enter image description here

3) And now you can upload your files to server from Pycharm. For this Right click to project folder->Upload to xxx. If all configuration is okay, now your files will upload to server and you can use auto-completion for your local files.

enter image description here

If it doesn't work, please try File->Invalidate cache. And let it delete all cache and download over it again.

Upvotes: 2

Related Questions