4

Issue:

I am using VSCode version 1.69.1 on Mac (Version details at the bottom). From Mac, I connect to a remote repo using SSH FS

When I click on 'run' > 'Start Debugging' or 'Run Without Debugging' on a remote python file, the "Run and Debug pane opens" but the file is not run [![Pane is blank][1]][1]

The debugger works for local repos (hosted on Mac).

I have tried reinstalling the Python extension, removed the ~/.vscode-server on the remote server, re-install VSCode on the Mac but nothing seem to have helped.

This was earlier working (tried a week back) but unsure what changed. From the terminal (connected to remote host, rendered by SSH FS, I am able to run python test.py and that works

Launch.json file for python

    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Current File",
            "type": "python",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "justMyCode": true
        }
    ]
}

Version details

Commit: b06ae3b2d2dbfe28bca3134cc6be65935cdfea6a
Date: 2022-07-12T08:21:51.333Z (1 day ago)
Electron: 18.3.5
Chromium: 100.0.4896.160
Node.js: 16.13.2
V8: 10.0.139.17-electron.0
OS: Darwin x64 21.5.0
Id: Kelvin.vscode-sshfs
Description: File system, terminal and task provider using SSH
Version: 1.25.0
Publisher: Kelvin Schoofs
VS Marketplace Link: https://marketplace.visualstudio.com/items?itemName=Kelvin.vscode-sshfs```


  [1]: https://i.sstatic.net/elruD.png
2
  • 1
    do you get an error? if so, can you add an image of the error? Commented Jul 13, 2022 at 18:53
  • Thanks @Aking for taking a look. No, there was no error. For local files when I click run I see following in the terminal: cd /Users/dev/src/nilebot ; /usr/bin/env /usr/local/bin/python3 /Users/dev/.vscode/extensions/ms-python.python-2022.10.0/pythonFiles/lib/python/debugpy/adapter/../../debugpy/launcher 56060 -- /Users/dev/test.py For remote files, I do not see anything on the terminal. Looks like something that triggers the command is broken. Commented Jul 14, 2022 at 3:01

2 Answers 2

10

Python Debugger version v2022.10.0 seems to be broken for SSH-FS. Using the previous version of Python extension addressed it.

To install an older version of an extension, click on gear icon> select "Install another version" and select version to install.

Install Another Version

I used version v2022.8.1, and that works

Sign up to request clarification or add additional context in comments.

2 Comments

In addition: It's important to do this in the ssh-rider under extensions. Accidentally I reverted the locally installed version without any effects.
This solved my issue, two subtle things though: restart your IDE after downgrading, and if you didn't use your IDE for a while it may happen that VS code automatically upgrades it to a higher version again (I don't know why, how or when , but for me it was the case, so check the version again if it stops working again).
0

My debugger was a version from two month ago, but the Python extension was from today. This mismatch caused all the problem. Once I rolled back the Python extension to a version from two months ago, the issue was fixed!

+1 to this thread

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.