Skip to content

Cell magics not properly handled in VS.Code Jupyter #3327

@timoklimmer

Description

@timoklimmer

Environment data

  • Language Server version: v2022.9.10
  • OS and version: Windows 11, Ubuntu 20.04
  • Python version: Python 3.10.5, conda 4.14.0

Repro Steps

  1. Create a Jupyter notebook in VS.Code
  2. Start a cell with a cells magic, for example %%cmd.
  3. Add some arbitrary code to the next lines.

Expected behavior

Whenever a cell's content starts with a cells magic (%%...), the code in the cell is not validated as Python code, and no wrong and disturbing squiggles are shown.

Ignoring all cell content when the cell starts with a %% seems like a good first step.

Actual behavior

Wrong and disturbing squiggles, making a convenient use of cell magics in VS.Code Jupyter impossible.

image

@debonte fyi
See also #2582

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestfixed in next version (main)A fix has been implemented and will appear in an upcoming version

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions