2 min

Microsoft updated Python support in Visual Studio Code by introducing web browser-editing capabilities. The company has archived its open-source Python language server to use the closed-source Pylance.

The Python Extension has over 41 million installs, according to data, compared to just over 3 million for a third-party Python extension, using pyLint or flake8 (both are open source) for the linter.

Language servers host the engine that drives VS Code editor’s programming language-specific features like syntax highlighting, code completion, and finding errors. Microsoft’s first time to offer a Python language server was in 2018 (it is open source.)

Pylance it is

Pylance was introduced last year in June. It gets its name from Monty Python and the Holy Grail’s version of Lancelot.

Pylance features rich type information when hovering over code symbols makes suggestions for smart imports, and does type checking (which users have the option of setting to ‘strict.’). The bad news for Python 2.7 coders is that support, which was based on the open-source Jedi Project, won’t be offered anymore.

The official advice to users is to upgrade to Python 3 or cross their fingers and use Pylance.

VS Code editing on a browser

Some Python libraries exist only in 2. x versions, which poses problems. However, Python 2.7’s runtime is still usable for a project. However, the smart code editor features won’t be reliable.

The new release is not just about transitioning to Pylance but also added web-editing support. Web editing in VS Code is implemented entirely in a browser. It is seen in github.dev and the announced and then retracted Visual Studio Code for the Web.

In this context, semantic highlighting, syntax errors, function signature help, and code navigation with outline support. The web version is convenient, as it doesn’t need an install. However, brace for a possible ‘uncanny valley’ where everything looks familiar but doesn’t quite feel like desktop VS Code.