Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

PyCharm remote deployment: user name not being saved

Working with Professional edition of PyCharm, I'm trying to configure a server for remote deployment of my project over SFTP with OpenSSH + authentication agent as auth type. I have tried to configure PyCharm in Settings > Build, Execution and Deployment > Add server. However, even though I setup and verify successful configuration by Test SFTP connection button, as soon as I click Apply or OK, the User name becomes blank for some reason. Thereafter, when I try to sync with the remote server, the connection fails.

I've found a possible workaround by changing Host name to user@host form instead, which works, but then I can't use the same server configuration when I try to setup a remote interpreter under Project > Project Interpreter > Add SSH interpreter. (there it shows my host url as ssh://null@host). I'm guessing the null is there because PyCharm is somehow not saving the username. I've tried to edit the .idea/webServers.xml file, but couldn't find appropriate key-value pair to change there for user name to be preserved.

Any help would be great!

like image 455
oczkoisse Avatar asked Jun 03 '18 23:06

oczkoisse


People also ask

How do I connect to a remote server in PyCharm?

Connect to a remote server and open the remote project Ensure you have the Remote Development Gateway plugin enabled. On the PyCharm welcome screen, select Remote Development. In the Run the IDE Remotely section, click SSH Connection.

How do I deploy in PyCharm?

on the main toolbar or press Ctrl+Alt+S to open the Settings/Preferences dialog, and choose the Deployment page (you can access the same page by choosing Tools | Deployment | Configuration from the main menu).


1 Answers

I solved it by changing the standard way to change credentials in Pycharm.

To do this go to Settings/Preferences | Appearance & Behavior | System Settings | Passwords and choose the KeePass option. That solved the problem for me.

Apparently there are problems storing on native keychain. (I'm on Mint 18.3)

like image 177
SimonCW Avatar answered Sep 23 '22 23:09

SimonCW