You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
with shell integration enabled, if i cause an exception in the repl the traceback points to an "import platform" line instead of the actual error
Steps to reproduce:
ensure "python > terminal > shell integration" is enabled in settings
open a shell and then a python repl
run something like raise 5
Python 3.13.7 (main, Aug 15 2025, 12:34:02) [GCC 15.2.1 20250813] on linux
Type "help", "copyright", "credits" or "license" for more information.
Ctrl click to launch VS Code Native REPL
>>> raise 5
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
import platform
^^^^^^^
TypeError: exceptions must derive from BaseException
Diagnostic data
Output for Python in the Output panel (View→Output, change the drop-down the upper-right of the Output panel to Python)
2025-09-20 13:20:35.434 [info] Telemetry is disabled
2025-09-20 13:20:35.434 [info] Experiments are disabled, only manually opted experiments are active.
2025-09-20 13:20:35.434 [warning] Dir "/home/me/project/.pixi/envs" is not watchable (directory does not exist)
2025-09-20 13:20:35.441 [info] Python interpreter path: /bin/python
2025-09-20 13:20:35.518 [info] > pyenv which python
2025-09-20 13:20:35.518 [info] cwd: .
2025-09-20 13:20:45.181 [info] Pylance extension is not installed.
2025-09-21 21:50:36.054 [info] Discover tests for workspace name: undefined - uri: /home/me/.config/Code/User/settings.json
Extension version: 2025.14.0
VS Code version: Code 1.104.0 (f220831ea2d946c0dcb0f3eaa480eb435a2c1260, 2025-09-10T06:46:18.035Z)
OS version: Linux x64 6.16.7-200.fc42.x86_64
Modes:
190n Thank you for pinpointing what caused this. I was able to resolve the issue by disabling "Shell Integration (Preview)" and can now see tracebacks again.
Because we have not heard back with the information we requested, we are closing this issue for now. If you are able to provide the info later on, then we will be happy to re-open this issue to pick up where we left off.
Activity
ddxv commentedon Oct 10, 2025
190n Thank you for pinpointing what caused this. I was able to resolve the issue by disabling "Shell Integration (Preview)" and can now see tracebacks again.
anthonykim1 commentedon Oct 17, 2025
Can't seem to repro this. Do 190n you see the same in REPL outside of VS Code.
github-actions commentedon Nov 17, 2025
Because we have not heard back with the information we requested, we are closing this issue for now. If you are able to provide the info later on, then we will be happy to re-open this issue to pick up where we left off.
Happy Coding!
saleemrashid commentedon Jan 24, 2026
If anyone else is seeing this, it's python/cpython#137576, because the shell integration sets
PYTHON_BASIC_REPL=1andPYTHONSTARTUPto https://github.com/microsoft/vscode-python/blob/main/python_files/pythonrc.py, which causes this behavior. It's fixed in Python 3.14.