Microsoft is creating a new extensibility model for Visual Studio, its Windows IDE for coding everything from desktop applications to cloud-hosted microservices.
Extensions are a critical part of any IDE, both for third-party integrations and for specialist features that would add bloat if built into the core product. There are 3,890 of them listed in the Visual Studio Marketplace, with the most popular (the official GitHub extension) having 1.8 million downloads.
Visual Studio extensions cover every aspect of software development and are installed from a Microsoft-hosted repository
A regular source of amusement in the tech news world is seeing companies who once bragged about the wonders of some product or feature quickly turn against it when they have something newer and shinier to offer.
So it is with Visual Studio extensions. Despite their popularity, Program Manager Leslie Richardson wrote yesterday that extensions are "difficult to write" and that "inconsistent APIs, overwhelming architecture, and having to ask your teammates how to implement what should be a basic command are common feedback items from extension writers."
Worse still, she added: "Today's in-proc extensions have minimal restrictions over how they can influence the IDE and other extensions. Thus, they are free to corrupt Visual Studio if the extension experiences an error or crash."
Naturally the company now aims to overcome these problems, and is working on a new extension model that will be out of process, meaning better isolated from the code that runs the IDE itself. Despite this change, Richardson said "the new model will preserve the power and UI customizability options" of the old system.
Microsoft also promises to make extensions available "both locally and remotely" so that they run correctly in the cloud-hosted GitHub Codespaces environment. Richardson referred in her post to new asynchronous APIs (not supported in the current extensibility model), which will be better suited to remote development environments.
The plans are at an early stage and the company has invited developers to complete a survey about their extension preferences.
According to the last StackOverflow survey on the matter, it is Visual Studio Code (used by 50.7 per cent of developers) that is the most popular IDE, with Visual Studio in second place at 31.5 per cent. One now rather dated survey is not the whole story, but there is no doubting the wide use of Microsoft's overgrown open-source editor.
Note that there are currently 21,755 VS Code extensions in the company's Marketplace, more than five times as many as for Visual Studio, and the most popular, for Python, has been downloaded over 26 million times – figures that make the Windows IDE look like small beer in comparison. For Windows-specific development, though, Visual Studio remains near-essential; Microsoft still needs both, but it may make sense for the company to invest more in the cross-platform product.
There is also another one, Visual Studio for the Mac, born of an entirely different codebase, but with which Microsoft is now trying to share code in order to minimise duplication of effort. Both the Windows and Mac versions of Visual Studio currently use a framework called Managed Extensibility Framework (VS-MEF) as well as a shared VS Editor API.
Will this be swept away by the new model, or will the new thing build on the old thing under the covers? One of the issues with Visual Studio is there is a ton of legacy to support, and it is likely to be a long time before Microsoft can afford to drop support for the existing extension model, crash-prone or not. ®