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

ipykernel invalid install path with Git Bash, requires pressing cancel on a notification to start the install #8391

Closed
rzhao271 opened this issue Nov 30, 2021 · 6 comments
Assignees
Labels
info-needed Issue requires more information from poster notebook-execution Kernels issues (start/restart/switch/execution, install ipykernel) verified Verification succeeded
Milestone

Comments

@rzhao271
Copy link
Contributor

Testing #8359

My interpreter and kernel are both using the same Python install under AppData.
I'm guessing Git Bash requires / or \\ as directory separators here:

Screenshot

@DonJayamanne
Copy link
Contributor

DonJayamanne commented Nov 30, 2021

@rzhao271
Please could you go into the settings and enable verbose logging for Jupyter extension and try this again, then Please could you provide the logs from the Jupyter output panel?

@DonJayamanne DonJayamanne added the info-needed Issue requires more information from poster label Nov 30, 2021
@rzhao271
Copy link
Contributor Author

rzhao271 commented Nov 30, 2021

After enabling logging, the terminal has the same error message, but the output panel has the following:

Info 10:34:17: Cancel pending cells
Info 10:34:17: Cell 0 executed with state Idle
Info 10:34:18: Process Execution: > ~\AppData\Local\Programs\Python\Python39\python.exe -c "import ipykernel"
> ~\AppData\Local\Programs\Python\Python39\python.exe -c "import ipykernel"
Info 10:34:18: installMissingDependencies ~\AppData\Local\Programs\Python\Python39\python.exe
Info 10:34:18: Process Execution: > ~\AppData\Local\Programs\Python\Python39\python.exe -c "import ipykernel"
> ~\AppData\Local\Programs\Python\Python39\python.exe -c "import ipykernel"
Info 10:34:18: Process Execution: > ~\AppData\Local\Programs\Python\Python39\python.exe -c "import pip"
> ~\AppData\Local\Programs\Python\Python39\python.exe -c "import pip"
Info 10:34:20: Got result from python installer for ipykernel, result = 2

However, after I press the cancel button, the Installing ipykernel notification shows up again, and this time it successfully does a force reinstall of ipykernel:

Info 10:34:20: Got result from python installer for ipykernel, result = 2
Info 10:35:22: Got result from python installer for ipykernel, result = 2 <- this is when I pressed cancel
Info 10:35:22: Process Execution: > ~\AppData\Local\Programs\Python\Python39\python.exe -c "import pip"
> ~\AppData\Local\Programs\Python\Python39\python.exe -c "import pip"
Pip Installing ipykernel into ~\AppData\Local\Programs\Python\Python39\python.exe
>>>>>>>>>>>>>
Info 10:35:22: Process Execution: > ~\AppData\Local\Programs\Python\Python39\python.exe -m pip install -U --force-reinstall --user ipykernel
> ~\AppData\Local\Programs\Python\Python39\python.exe -m pip install -U --force-reinstall --user ipykernel

At the very end of the reinstall, the kernel dies

<<<<<<<<<<<<<<
Info 10:37:02: Process Execution: > ~\AppData\Local\Programs\Python\Python39\python.exe -c "import ipykernel"
> ~\AppData\Local\Programs\Python\Python39\python.exe -c "import ipykernel"
Info 10:37:04: Successfully installed with Jupyter extension
Error 10:37:04: DataScience Error o [Error]: The kernel died. View Jupyter [log](command:jupyter.viewOutput) for further details. 
Error: C:\Users\raymondzhao\AppData\Local\Programs\Python\Python39\python.exe: No module named ipykernel_launcher,...
    at c:\Users\raymondzhao\.vscode-insiders\extensions\ms-toolsai.jupyter-2021.11.1001520020\out\client\extension.js:66:1023321
    at c:\Users\raymondzhao\.vscode-insiders\extensions\ms-toolsai.jupyter-2021.11.1001520020\out\client\extension.js:66:695887
    at c:\Users\raymondzhao\.vscode-insiders\extensions\ms-toolsai.jupyter-2021.11.1001520020\out\client\extension.js:66:696105
    at Immediate._onImmediate (c:\Users\raymondzhao\.vscode-insiders\extensions\ms-toolsai.jupyter-2021.11.1001520020\out\client\extension.js:66:697670)
    at processImmediate (internal/timers.js:461:21) {
  category: 'kerneldied',
  errorMessage: 'C:\\Users\\raymondzhao\\AppData\\Local\\Programs\\Python\\Python39\\python.exe: No module named ipykernel_launcher, \n',
  stdErr: 'C:\\Users\\raymondzhao\\AppData\\Local\\Programs\\Python\\Python39\\python.exe: No module named ipykernel_launcher\r\n',
  exitCode: 1,
  reason: 'C:\\Users\\raymondzhao\\AppData\\Local\\Programs\\Python\\Python39\\python.exe: No module named ipykernel_launcher\r\n',
  vslsStack: [ CallSite {}, CallSite {}, CallSite {}, CallSite {}, CallSite {} ]
}

But I'm able to continue with the testplan item afterwards, and verify that ipykernel was successfully installed.

@rzhao271 rzhao271 changed the title ipykernel invalid install path with Git Bash ipykernel invalid install path with Git Bash, requires pressing cancel on a notification to start the install Nov 30, 2021
@DonJayamanne
Copy link
Contributor

@rzhao271 Thanks, I believe i've identified the issue.

@DonJayamanne
Copy link
Contributor

@rzhao271 please could you try this again today, with the latest jupyter vsix.

@DonJayamanne DonJayamanne added the notebook-execution Kernels issues (start/restart/switch/execution, install ipykernel) label Dec 1, 2021
@DonJayamanne DonJayamanne added this to the November 2021 milestone Dec 1, 2021
@rzhao271
Copy link
Contributor Author

rzhao271 commented Dec 1, 2021

LGTM!

@DonJayamanne
Copy link
Contributor

DonJayamanne commented Dec 1, 2021

I think we can then close this issue, please feel free to re-open if still repros or doesn't work as expected.

@DonJayamanne DonJayamanne added the verified Verification succeeded label Dec 1, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 1, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
info-needed Issue requires more information from poster notebook-execution Kernels issues (start/restart/switch/execution, install ipykernel) verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

2 participants