code-server icon indicating copy to clipboard operation
code-server copied to clipboard

Can't use Python extension

Open konradzadroga opened this issue 5 years ago • 10 comments

Dear Team,

I am experiencing issue with code-server (latest version, 3.8.0, inside Docker container). After installing 'Python' extension I can't use it because of some dependencies. Errors in the console:

"Activating extension 'ms-toolsai.jupyter' failed: Cannot find module '/home/coder/.local/share/code-server/extensions/ms-toolsai.jupyter-2020.12.1/out/client/extension'
Require stack:
- /usr/lib/code-server/lib/vscode/out/vs/loader.js
- /usr/lib/code-server/lib/vscode/out/bootstrap-amd.js
- /usr/lib/code-server/lib/vscode/out/bootstrap-fork.js."
"Cannot activate extension 'Python' because it depends on extension 'ms-toolsai.jupyter', which failed to activate."

I would be thankful if you will provide me with some workaround.

Thank you :)

  • Web Browser: Google Chrome
  • Local OS: Windows 10
  • Remote OS: Ubuntu 18.04
  • Remote Architecture: ALB + EC2 + Openresty + code-server inside Docker container
  • code-server --version: 3.8.0

konradzadroga avatar Feb 05 '21 15:02 konradzadroga

Hi @konradzadroga - sorry to hear you'rve having issues with the Python extension!

Do you mind seeing if this issue has already been opened? Possible duplicates:

  • https://github.com/cdr/code-server/issues/1837
  • https://github.com/cdr/code-server/issues/2341

jsjoeio avatar Feb 05 '21 16:02 jsjoeio

Can confirm, exact same error on the front end. I am on an EC2 Amazon Linux 2 VM. There is no /home/coder/.local/share/code-server/extensions/ms-toolsai.jupyter-2020.12.1/client directory at all. I am using an SSH tunnel to access code-server. I have also tried with an HTTPS server.

I see this on the client output when I click on the Python extension in the extensions tab: Blocked script execution in 'https://dev.spurious.ninja/webview/fake.html?id=extensionEditor' because the document's frame is sandboxed and the 'allow-scripts' permission is not set.

stefanba3 avatar Feb 09 '21 02:02 stefanba3

Thanks for the additional information!

Can confirm, exact same error on the front end

So this issue is a duplicate then? If so, we're going to close this issue. That will make it easier for us to track and fix this.

Looks like you may want to look at this workaround

jsjoeio avatar Feb 09 '21 17:02 jsjoeio

This might be #2341, I'll look into it a bit and report back.

stefanba3 avatar Feb 10 '21 04:02 stefanba3

This might be #2341, I'll look into it a bit and report back.

Installing 2020.10.332292344 from the Manage menu on the extension fixed this for me. Thanks! Similar workaround to #2341, but can just do it straight from the UI.

stefanba3 avatar Feb 10 '21 05:02 stefanba3

Hooray! Sorry you had to use a workaround. We're close to switching over to a new extension marketplace which I hope helps with issues like these. Closing for now. Feel free to subscribe to the other issue so you get notified when a formal fix happens!

jsjoeio avatar Feb 10 '21 17:02 jsjoeio

This might be #2341, I'll look into it a bit and report back.

Installing 2020.10.332292344 from the Manage menu on the extension fixed this for me. Thanks! Similar workaround to #2341, but can just do it straight from the UI.

Can you confirm what that is? Version of what? Extension? code-server?

ediphy-dcottrell avatar Mar 25 '21 14:03 ediphy-dcottrell

This might be #2341, I'll look into it a bit and report back.

Installing 2020.10.332292344 from the Manage menu on the extension fixed this for me. Thanks! Similar workaround to #2341, but can just do it straight from the UI.

Can you confirm what that is? Version of what? Extension? code-server?

The extension. I also had to turn off automatic updates for it.

stefanba3 avatar Mar 25 '21 15:03 stefanba3

This might be #2341, I'll look into it a bit and report back.

Installing 2020.10.332292344 from the Manage menu on the extension fixed this for me. Thanks! Similar workaround to #2341, but can just do it straight from the UI.

I had the same issue this morning (everything worked fine until an update). I tried all recent versions of Python's extension and only this one worked. Is there an actual fix for this issue (rather than using an 8-month old version and disabling further updates)?

keurfonluu avatar May 11 '21 18:05 keurfonluu

I just installed the latest version v2021.5.829140558 with code-server 3.10.0 and it appears to be working.

@keurfonluu If you think you've found a bug, please open a separate bug report and we'll be happy to look into it.

https://user-images.githubusercontent.com/3806031/117868340-58169400-b24e-11eb-8150-ad624b7b26ed.mov

jsjoeio avatar May 11 '21 18:05 jsjoeio