Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python plugin randomly crashes #14074

Closed
3 of 19 tasks
amisevsk opened this issue Jul 30, 2019 · 6 comments
Closed
3 of 19 tasks

Python plugin randomly crashes #14074

amisevsk opened this issue Jul 30, 2019 · 6 comments
Labels
area/plugin-registry kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.
Milestone

Comments

@amisevsk
Copy link
Contributor

Describe the bug

When using both the python-simple and python-django devfiles, I get random crashes for the python language server container (disappears, OpenShift says exit code 1). In the container logs, I see


Info Python Extension: 2019-07-30 16:54:55: Get language server folder name, Class name = f, completed in 2ms, Arg 1: <Uri:/projects>, Return Value: "languageServer.0.3.43"
--
  | events.js:174
  | throw er; // Unhandled 'error' event
  | ^
  |  
  | Error: spawn /tmp/vscode-unpacked/ms-python.python.latest.tlnvuvjhxp.ms-python-release.vsix/extension/languageServer.0.3.43/Microsoft.Python.LanguageServer ENOENT
  | at Process.ChildProcess._handle.onexit (internal/child_process.js:240:19)
  | at onErrorNT (internal/child_process.js:415:16)
  | at process._tickCallback (internal/process/next_tick.js:63:19)
  | Emitted 'error' event at:
  | at Process.ChildProcess._handle.onexit (internal/child_process.js:246:12)
  | at onErrorNT (internal/child_process.js:415:16)
  | at process._tickCallback (internal/process/next_tick.js:63:19)

Additionally, sometimes I see a prompt at the top:

Try out Preview of our new Python Language Server to get richer and faster IntelliSense completions, and syntax errors as you type.

which I assume is inappropriate for Che.

Che version

  • latest
  • nightly
  • other: please specify

Steps to reproduce

I don't have a consistent reproducer; it occurs within 50 seconds of workspace start, on every start.

Expected behavior

Working python language features

Runtime

  • kubernetes (include output of kubectl version)
  • Openshift (include output of oc version)
    • (OSIO)
  • minikube (include output of minikube version and kubectl version)
  • minishift (include output of minishift version and oc version)
  • docker-desktop + K8S (include output of docker version and kubectl version)
  • other: (please specify)

Environment

  • my computer

    • Windows
    • Linux
    • macOS
  • Cloud

    • Amazon
    • Azure
    • GCE
    • other (OSIO)
  • other: please specify

@amisevsk amisevsk added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Jul 30, 2019
@amisevsk
Copy link
Contributor Author

Additionally, I get a prompt

A new process is now listening on port 2503 but this port is not exposed in the workspace as a server.
Would you want to add a redirect for this port so it becomes available ?

At the top of the window; exposing this port just leads to a webpage that says "Upgrade required"

@ibuziuk
Copy link
Member

ibuziuk commented Jul 31, 2019

@svor could you please take a look ?

@amisevsk amisevsk added area/plugin-registry kind/bug Outline of a bug - must adhere to the bug report template. labels Jul 31, 2019
@svor
Copy link
Contributor

svor commented Jul 31, 2019

Is this something related to #13599?

@amisevsk
Copy link
Contributor Author

@svor The issue is not with the server trying to start AFAICT, but rather that it's trying to update itself like it would on vscode. The python language server was working for me last week, but I was getting prompts to "update the plugin" in theia. I suspect the issue is that it's forcing the update now.

I see that #13599 has been reopened so it may be reproducing the same issue now, but the initial description and discussion do not match as far as I can tell.

@slemeur slemeur added team/languages severity/P1 Has a major impact to usage or development of the system. and removed status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. labels Jul 31, 2019
@slemeur slemeur added this to the 7.1.0 milestone Jul 31, 2019
@che-bot che-bot added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Aug 1, 2019
@benoitf benoitf removed the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Aug 1, 2019
@amisevsk
Copy link
Contributor Author

It appears that this issue is caused by clicking the "Try it now!" on the prompt that appears when starting a workspace:

Screenshot from 2019-08-13 13-39-36

This creates the entry "python.jediEnabled": false in the user preferences, which causes the crashing. As a workaround, the setting can be removed and the workspace restarted.

From an end-user perspective, pressing the "Try it now!" button is a normal thing to do, and the resulting error is very hard to diagnose.

@tsmaeder tsmaeder mentioned this issue Aug 14, 2019
24 tasks
@tsmaeder tsmaeder mentioned this issue Aug 29, 2019
41 tasks
@tolusha
Copy link
Contributor

tolusha commented Sep 3, 2019

My assumption is that some package is missed in the container.
Docker file [1] for python is huge. We have to start with refactoring here:

  1. Find appropriate base image in the registry
  2. Installed required packages ptsvd, pylint, python-language-server[all], jedi
  3. Find and installed missed ones

[1] https://github.com/eclipse/che-theia/blob/ab/scc/dockerfiles/remote-plugin-python-3.7.3/Dockerfile#L122
[2] https://hub.docker.com/_/python

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/plugin-registry kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system.
Projects
None yet
Development

No branches or pull requests

7 participants