Microsoft Updates Its Python Extension For Visual Studio Code

Microsoft Updates Its Python Extension For Visual Studio Code

Microsoft has introduced a wide range of improvements to its popular Python extension for Visual Studio Code to empower developers to work faster and smarter than ever. With the new update, the company has launched Pylance, making it the default language server for Python with an auto-reload debugger for Python scripts.

Pylance is a Python language support extension from Microsoft that provides thoughtful feedback and type details to help developers write code faster. It’s based on Python’s Microsoft’s Pyright static type-checking tool released in 2019, allowing developers to clean up and auto-complete code snippets securely and efficiently.

According to Microsoft, the May 2021 upgrade also brings significant improvements in reliability and performance, as well as a faster start-up period. Due to advancements in its Python environments discovery process, the company claims a 10% faster boot time for Windows and macOS customers and a 20% faster boot time for Linux customers. They have also seen a 15% reduction in the number of times the Python extension becomes unresponsive across the board.

The company reported that they believe this is the most performant and user-friendly Python editing experience for Visual Studio Code. Since its launch last year, Microsoft has been improving Python language support through the Pylance extension. The company has been working on improving language support for developers, whether they’re using Pylance or a different language server, and hopes to concentrate on offering open-source language support options for customers in the future.

Savannah Ostrowski, Program Manager of Pylance and Python in Visual Studio at Microsoft, said, “We’ve invested resources to standardize the way that language servers communicate with the Python extension (via Language Server Protocol). This work has enabled us to improve further the performance and overall experience of other language servers, like the open-source Jedi language server.”

Microsoft has also launched a new debugger feature that adds live reload to Python files previously only supported by Django and Flask. This means that changes can be made in the codes even after the debugger has reached a breakpoint without restarting the debugger.

VS Code has made several changes and improvements to Python, including:

  • A “Default” language server option to choose which language server to use based on the current situation.
  • Automatic indenting following `match` and `case` statements
  • The Refresh TensorBoard command has been added to python.
  • Compatibility with the pypy3.7 interpreter has been added.

Users can get the Python extension here. They can install it directly from the Visual Studio Code extension gallery.

Abhishek Singh

Full Stack Technical Lead

A highly motivated Senior Full Stack Developer who is self-driven and actively looks for ways to contribute to the team. He possesses rich expertise and deep knowledge about a good software development process that includes documentation, testing, documentation, and collaboration. With solid communications and reasoning skills, he delivers high performance and quality in his projects. He is always open to assist other teams in understanding project requirements so that collaboration can happen in the best possible ways in an environment conducive to the business.

Leave a Reply