Display path not working, run script ssh interpreter pychram

I have AWS and I am connecting to the server using pychram-ssh-deployment.
When I run the script (using right click -> run, ctrl+shift+F10

) I got the following error.

ssh://user@xxx.xx.x.xx:22/data/anaconda/bin/python /home/user/.pycharm_helpers/pydev/pydev_run_in_console.py 0 0 C:/WC/trunk/content_dna/src/predict_hidden_layer.py
    globals = run_file(file, None, None)
  File "/home/user/.pycharm_helpers/pydev/pydev_run_in_console.py", line 35, in run_file
    pydev_imports.execfile(file, globals, locals)  # execute the script
  File "/home/user/.pycharm_helpers/pydev/_pydev_imps/_pydev_execfile.py", line 11, in execfile
    stream = tokenize.open(file)  # @UndefinedVariable
  File "/data/anaconda/lib/python3.5/tokenize.py", line 454, in open
    buffer = _builtin_open(filename, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: 'C:/WC/trunk/content_dna/src/predict_hidden_layer.py'
Process finished with exit code 1

      

But if I change Working Directory and script Run / Debug Config to \home\user\PycharmProjects\content_dna\src

\home\user\PycharmProjects\content_dna\src\get_imdb_keyword.py


script it works fine.

I want it to be automatic, I tried to add path mapping in three places:

  • Settings -> project interpreter -> Edit project path mappings (three dots only available in remote interpreter).
  • Run -> Modify Config -> Default -> Python -> Path Mappings
  • Tools -> Deployment -> Configuration -> Mapping.

Now the weird thing is if I try to use Debug (right click -> debug or Shift+F9

), no problem.

+3


source to share


1 answer


Have you checked the option: show command line after? I had a similar problem. But after discarding this option, my problem is resolved.



0


source







All Articles