News

Improved IntelliSense Support for Jupyter Notebooks in VS Code

Improved IntelliSense support for Jupyter Notebooks highlights the September 2022 update of Python dev tooling in Visual Studio Code.

That tooling comes in extensions for Python (64 million installs, making it by far the most popular VS Code tool), Jupyter (nearly 45 million installs) and Pylance, the language server that provides Python-specific "smarts" in the code editor, such as code completion, parameter suggestions, semantic highlighting and so on.

It's that latter language server tool and the associated Language Server Protocol that are responsible for the improved IntelliSense support, said the dev team in a Sept. 1 announcement post.

"IntelliSense support for Jupyter Notebooks with Python kernels is now much better when using Pylance, thanks to the updates in the Language Server Protocol to include notebook support," Microsoft's Erik De Bonte said.

"Not only you will get improved auto complete suggestions when writing Python code in notebook files, but you will also be able to leverage refactoring features such as extract variable, extract method as well as auto imports."

Improved IntelliSense Support for Jupyter Notebooks in Animated Action
[Click on image for larger, animated GIF view.] Improved IntelliSense Support for Jupyter Notebooks in Animated Action (source: Microsoft).

Indeed, the changelog for the Jupyter tool shows 15 different items that mention IntelliSense.

In addition, the team announced a new extension that also leverages the Language Server Protocol -- in this case for linting support for files using the Flake8 linter -- called Flake8. It joins several other extensions that provide linting functionality (flagging programming/style errors, bugs and suspicious constructs), code formatting and sorting.

"After releasing extensions for pylint, black and isort, we are now excited to announce we also have a new flake8 extension!" said De Bonte. "Much like the others, this new extension uses the Language Server Protocol to provide linting support, and because it ships with the latest version of Flake8, you're no longer required to have it installed in a Python environment.

"You can also use it side by side with the Pylint extension, as one doesn't conflict with the other."

Also, many small enhancements and fixes were enacted in response to developer feedback, including:

  • Developers can now clear and refresh the Python interpreters list through a new button in the picker (vscode-python#19628).
  • Debugpy has been updated to version 1.6.3 (vscode-python#19698)
  • Pylance is now longer showing false warnings when importing a Python module/file in a Jupyter notebook (pylance-release#3017).
  • Renaming symbols across different cells in Jupyter notebooks no longer fails when using Pylance (pylance-release#3061).
  • IntelliSense support for matplotlib has been improved when using Pylance thanks to updates on matplotlib type stubs (python-type-stubs#223).

To figure out how to use all that tooling, Microsoft provides "Getting Started with Python in VS Code" documentation.

About the Author

David Ramel is an editor and writer at Converge 360.

comments powered by Disqus

Featured

  • GitHub Previews Agentic AI in VS Code Copilot

    GitHub announced a raft of improvements to its Copilot AI in the Visual Studio Code editor, including a new "agent mode" in preview that lets developers use the AI technology to write code faster and more accurately.

  • Copilot Engineering in the Cloud with Azure and GitHub

    Who better to lead a full-day deep dive into this tech than two experts from GitHub, which introduced the original "AI pair programmer" and spawned the ubiquitous Copilot moniker?

  • Uno Platform Wants Microsoft to Improve .NET WebAssembly in Two Ways

    Uno Platform, a third-party dev tooling specialist that caters to .NET developers, published a report on the state of WebAssembly, addressing some shortcomings in the .NET implementation it would like to see Microsoft address.

  • Random Neighborhoods Regression Using C#

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of the random neighborhoods regression technique, where the goal is to predict a single numeric value. Compared to other ML regression techniques, advantages are that it can handle both large and small datasets, and the results are highly interpretable.

  • As Some Orgs Restrict DeepSeek AI Usage, Microsoft Offers Models and Dev Guidance

    While some organizations are restricting employee usage of the new open source DeepSeek AI from a Chinese company due to data collection concerns, Microsoft has taken a different approach.

Subscribe on YouTube

Upcoming Training Events