Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with Virtual Environment Name Display in VSCode Terminal #24033

Closed
byeongryul-cho opened this issue Sep 3, 2024 · 3 comments
Closed

Issue with Virtual Environment Name Display in VSCode Terminal #24033

byeongryul-cho opened this issue Sep 3, 2024 · 3 comments
Assignees
Labels
triage-needed Needs assignment to the proper sub-team

Comments

@byeongryul-cho
Copy link

Type: Bug

Behaviour

When I activate a virtual environment, regardless of what I type in the terminal, the virtual environment name(.venv) is displayed at the end of each line. This issue doesn't occur when I disable the VSCode extension(Python).

Plus, Add the following option ("python.terminal.activateEnvironment": false) to the config, set it so that the virtualenv is not automatically activated in the terminal, and then manually activate it in the terminal each time. This will resolve the issue.

Steps to reproduce:

  1. Just Open Python Project in IDE(Cussor, VSCode)
359826475-40ad8709-e167-45d7-adf3-bb8a0c0bb7ed

Diagnostic data

launch.json configuration

Nothing

Output for Python in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python)

Nothing, I didn't execute any python code

Output for Python Debugger in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python Debugger)

Nothing, I didn't execute any python code

Extension version: 2024.12.3
VS Code version: Cursor 0.40.3 (2804893a83ef162ae6c48e8254717e25c7c7c510, 2024-08-29T17:42:50.254Z)
OS version: Darwin arm64 23.6.0
Modes:

System Info
Item Value
CPUs Apple M1 (8 x 2400)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: enabled
webgl: enabled
webgl2: enabled
webgpu: enabled
Load (avg) 4, 3, 2
Memory (System) 16.00GB (0.03GB free)
Process Argv
Screen Reader no
VM 0%
@github-actions github-actions bot added the triage-needed Needs assignment to the proper sub-team label Sep 3, 2024
@byeongryul-cho
Copy link
Author

byeongryul-cho commented Sep 4, 2024

FYI, I am using starship and zshrc. I don't know if this matters.

@anthonykim1
Copy link

Hello @byeongryul-cho, thank you for filing this issue - This
has been brought up here: #23304 and #23137. Feel free to give them a read.

Right now, you should be able to add:

"python.experiments.optOutFrom": ["pythonTerminalEnvVarActivation"],

to your settings.json and opt out of the terminal env var experiment. - Thanks

@anthonykim1 anthonykim1 closed this as not planned Won't fix, can't repro, duplicate, stale Sep 8, 2024
@byeongryul-cho
Copy link
Author

Hello @anthonykim1, It works well! Thank you

Screenshot 2024-09-10 at 10 45 22 AM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage-needed Needs assignment to the proper sub-team
Projects
None yet
Development

No branches or pull requests

2 participants