Skip to content

Intellisense not working with jupyter extension #15702

Closed as not planned
Closed as not planned
@tmchartrand

Description

@tmchartrand

Applies To

  • Notebooks (.ipynb files)
  • Interactive Window and/or Cell Scripts (.py files with #%% markers)

What happened?

With a new python environment, created a new notebook and interactive window with a single import statement (import os). Intellisense does not work on this import (either hover hint or go to def). This is true for both Jedi and Pylance language server. Pylance does give an error in the log:

2024-05-21 10:07:22.134 [info] a [Error]: Request workspace/configuration failed with message: Cannot read properties of undefined (reading 'metadata')
    at /Users/tom.chartrand/.vscode/extensions/ms-python.vscode-pylance-2024.3.2/dist/vendor.bundle.js:2:1268722
    at oe (/Users/tom.chartrand/.vscode/extensions/ms-python.vscode-pylance-2024.3.2/dist/vendor.bundle.js:2:1269016)
    at /Users/tom.chartrand/.vscode/extensions/ms-python.vscode-pylance-2024.3.2/dist/vendor.bundle.js:2:1263775
    at Immediate.<anonymous> (/Users/tom.chartrand/.vscode/extensions/ms-python.vscode-pylance-2024.3.2/dist/vendor.bundle.js:2:1263795)
    at processImmediate (node:internal/timers:476:21) {
  code: -32603,
  data: undefined
}

Intellisense comes back in these windows if the jupyter extension is disabled. In some cases Pylance does work inconsistently, seemingly dependent on what is open when the window is reloaded (if only preferences are focused, I get no error and intellisense works, but not sure how consistent this is), but Jedi seems consistently blocked.

VS Code Version

1.89.1

Jupyter Extension Version

v2024.4.2024042601 (pre-release)

Jupyter logs

Visual Studio Code (1.89.1, undefined, desktop)
Jupyter Extension Version: 2024.4.2024042601.
Python Extension Version: 2024.6.0.
Pylance Extension Version: 2024.3.2.
Platform: darwin (arm64).
No workspace folder opened.
10:07:22.142 [info] Process Execution: ~/micromamba/bin/python -m pip list

Coding Language and Runtime Version

No response

Language Extension Version (if applicable)

No response

Anaconda Version (if applicable)

No response

Running Jupyter locally or remotely?

Local

Metadata

Metadata

Labels

bugIssue identified by VS Code Team member as probable buginfo-neededIssue requires more information from postertriage-neededIssue needs to be triaged

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions