We’re excited to announce the February 2025 release of the Python, Pylance and Jupyter extensions for Visual Studio Code!
This release includes the following announcements:
- No-config debugging
- Test discovery cancellation
- Launch the Native REPL from the terminal
- Go to Implementation with Pylance
- AI Code Action: Generate Symbol (Experimental)
If you’re interested, you can check the full list of improvements in our changelogs for the Python, Jupyter and Pylance extensions.
No-config debugging
After listening to community feedback that configuring the debugger can be difficult, we are introducing a no-config debugging experience! We are excited to say that this is now available in the Python Debugger extension!
As the name implies, this workflow allows you to start the debugger without creating or managing a Python debug configuration in launch.json
. Simply replace python
with debugpy
prefixed in your run command in the terminal, for example debugpy <script.py or module>
, to start a debug session.
NOTE: We also recommend adding the following to your User
settings.json
file:"python.experiments.optOutFrom": ["pythonTerminalEnvVarActivation"]
as this experiment is known to conflict with this new feature. You can still activate your terminals using normal activation commands.
You’ll see feedback in the terminal that a debug session is starting and the debug toolbar pop up in the editor. Set breakpoints in the UI and open up the debug toolbar to use all of VS Code’s debugging functionality.
For more information and troubleshooting tips, check out the no-config debugging wiki. We would love to hear your feedback on this new feature – you can open issues and feature requests in our repository.
Test discovery cancellation
When triggering test discovery from the Test Explorer UI, you can now cancel an ongoing test discovery call. Use the Cancel Test Refresh button, which appears in replacement of the Refresh button during discovery.
Launch the Native REPL from the terminal
You are now able to launch a VS Code Native REPL from your terminal REPL. By setting python.terminal.shellIntegration.enabled
to true
, a clickable link will display in the Python REPL in the terminal, allowing you to directly open the VS Code Native REPL from the terminal. This will eventually be set to true
by default, but for now you can enable it manually.
The Native REPL allows you to iteratively run Python code similar to the Python REPL located in the terminal enhanced with features such as IntelliSense and syntax highlighting.
Go to Implementation with Pylance
Pylance now has support for Go to Implementation, which allows you to more quickly navigate to the implementation of a function or method directly from its usage. This feature is particularly helpful when working with inherited classes.
AI Code Action: Generate Symbol (Experimental)
There’s a new experimental AI Code Action for generating symbols with Pylance and Copilot. To try it out, you can enable the following setting: "python.analysis.aiCodeActions": {"generateSymbol": true}
.
With this enabled, once you define a new symbol, such as a class, function, or variable, you can select the Generate Symbol with Copilot Code Action and let Copilot handle the implementation! Afterward, you can leverage Pylance’s Move Symbol Code Actions to relocate it to a different file.
Other Changes and Enhancements
We have also added small enhancements and fixed issues requested by users that should improve your experience working with Python and Jupyter Notebooks in Visual Studio Code. Some notable changes include:
- This release is the last release with support for Python 3.8 in all our extensions (Python extension, Python Debugger, Python Environments, and Python tooling extensions).
- The Python Environments extension APIs now support grouping environments by environment managers and allows package managers to control the common package lists, providing more flexibility to providers.
We would also like to extend special thanks to this month’s contributors:
- Use fnmatch instead of pathlibs match by @Mutantpenguin in @vscode-flake8#256
- Change the flake8 version string in
readme.md
to be pip compatible by @safiyat in @vscode-flake8#257 - Fix link in README.md by @maxg203 in @vscode-flake8#269
- Use global settings for
ignorePatterns
default by @taesungh in @vscode-flake8#327 - Workaround for memory leak caused by pylint bug by @DetachHead in @vscode-pylint#585
- Run mypy in the directory of the nearest pyproject.toml or mypy.ini by @jwhitaker-gridcog in @vscode-mypy#316
- Use global settings for
ignorePatterns
default by @taesungh in @vscode-mypy#325 - Fix: address dev-dependency issues reported by
npm audit
by @hamirmahal in @vscode-mypy#327 - Fix: usage of
node12 which is deprecated
in CI by @hamirmahal in @vscode-mypy#336 - Fix for conda listing in README.md by @jezdez in @vscode-python-environments#80
- Added note of ms-python.python pre-release requirement by @robwoods-cam in @vscode-python-environments#111
- Untildify conda path from settings by @almarouk in @vscode-python-environments#122
- Quote arguments systematically when calling conda by @almarouk in @vscode-python-environments#121
- Handle all shells’ de/activation by @flying-sheep in @vscode-python-environments#137
Try out these new improvements by downloading the Python extension and the Jupyter extension from the Marketplace, or install them directly from the extensions view in Visual Studio Code (Ctrl + Shift + X or ⌘ + ⇧ + X). You can learn more about Python support in Visual Studio Code in the documentation. If you run into any problems or have suggestions, please file an issue on the Python VS Code GitHub page.
0 comments
Be the first to start the discussion.