Skip to content

Pipenv not activating venv on Gitbash #22957

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

Closed
lukaszwojcik89 opened this issue Feb 22, 2024 · 4 comments
Closed

Pipenv not activating venv on Gitbash #22957

lukaszwojcik89 opened this issue Feb 22, 2024 · 4 comments
Assignees
Labels
experimenting Feature is part of an experiment triage-needed Needs assignment to the proper sub-team

Comments

@lukaszwojcik89
Copy link

Type: Bug

Hey.

I wanted to report a problem like this. I code in Python, and I use Pipenv as a virtual environment manager every day. So far, VSCode automatically detected the environment created via pipenv and selected it as active.

Unfortunately, for the past few days I've been having a huge problem with this. I don't know if it's a matter of updating the extension for python or the program itself, but VSCode has stopped detecting environments automatically. Even when I manually select it as the default interpreter for a given workspace it is not properly activated and all packages install "outside" the environment.

I also noticed that after activating the environment, the prompt indicating that it is active (i.e. with the environment name in parentheses) is no longer displayed. Previously there were no such problems so I assume it is either related to extension Python or to VSCode itself (both were recently updated).

Of the things I checked on my own to find the cause of the issue are:

  • tried to create new "clean" profiles (with only the necessary extensions),
  • clean reinstallation of VSCode,
  • reinstallation of Python. Nothing had any effect.

Has anyone perhaps had similar problems? Is there any way to solve this?

VS Code version: Code 1.86.2 (903b1e9d8990623e3d7da1df3d33db3e42d80eda, 2024-02-13T19:40:56.878Z)
OS version: Windows_NT x64 10.0.22621
Modes:

System Info
Item Value
CPUs 13th Gen Intel(R) Core(TM) i5-1335U (12 x 2496)
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
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
Load (avg) undefined
Memory (System) 47.68GB (31.70GB free)
Process Argv --crash-reporter-id 6cfb77d3-1c60-47b8-ac71-5c9b9e24299d
Screen Reader no
VM 0%
Extensions (100)
Extension Author (truncated) Version
better-comments aar 3.0.2
Bookmarks ale 13.4.2
project-manager ale 12.7.0
vscode-sqlite ale 0.14.1
intellij-theme arz 1.11.0
vscode-django bat 1.15.0
github-markdown-preview bie 0.3.0
markdown-checkbox bie 0.4.0
markdown-emoji bie 0.3.0
markdown-footnotes bie 0.1.1
markdown-mermaid bie 1.22.0
markdown-preview-github-styles bie 2.0.3
markdown-yaml-preamble bie 0.1.0
vscode-tailwindcss bra 0.10.5
vscode-better-align cho 1.4.2
path-intellisense chr 2.8.5
sqlnotebook cmo 0.7.0
gitignore cod 0.9.0
vscode-markdownlint Dav 0.54.0
macos-modern-theme dav 2.3.19
vscode-eslint dba 2.4.4
make-hidden dev 4.0.4
python-environment-manager don 1.2.4
python-extension-pack don 1.7.0
yapf eey 2023.12.104100706
LogFileHighlighter emi 2.18.0
vsc-material-theme Equ 34.3.1
prettier-vscode esb 10.1.0
git-project-manager fel 1.8.2
auto-close-tag for 0.5.15
auto-rename-tag for 0.1.10
code-runner for 0.12.1
docker-explorer for 0.1.7
vscode-yarn gam 2.1.0
duplicate gee 1.0.2
codespaces Git 1.16.10
remotehub Git 0.62.0
gc-excelviewer Gra 4.2.58
todo-tree Gru 0.0.226
material-color guo 1.4.3
vscode-test-explorer hbe 2.21.1
codesnap-plus hui 1.4.1
output-colorizer IBM 0.1.2
react-component jer 1.1.0
vsc-python-indent Kev 1.18.0
vscode-gutter-preview kis 0.30.0
break-time Lor 1.0.1
start-git-bash McC 1.2.1
rainbow-csv mec 3.11.0
python-path mge 0.0.14
language-gettext mro 0.4.0
vscode-docker ms- 1.29.0
vscode-postgresql ms- 0.3.0
autopep8 ms- 2023.8.0
black-formatter ms- 2024.0.1
isort ms- 2023.10.1
python ms- 2024.0.1
vscode-pylance ms- 2024.2.2
remote-containers ms- 0.338.1
remote-ssh ms- 0.108.0
remote-ssh-edit ms- 0.86.0
remote-wsl ms- 0.86.0
powershell ms- 2024.0.0
remote-explorer ms- 0.4.1
remote-repositories ms- 0.40.0
remote-server ms- 1.5.0
test-adapter-converter ms- 0.1.9
color-highlight nau 2.5.0
back-n-forth nic 3.1.1
autodocstring njp 0.6.1
indent-rainbow ode 8.3.1
vscode-versionlens pfl 1.9.2
material-icon-theme PKi 4.34.0
material-product-icons PKi 1.7.0
postman-for-vscode Pos 0.18.0
quicktype qui 12.0.46
sqlite-viewer qwt 0.3.13
vscode-yaml red 1.14.0
jinjahtml sam 0.20.0
python-init-generator See 0.0.12
trailing-spaces sha 0.4.1
pip-manager sli 1.1.3
swdc-vscode sof 2.7.5
guides spy 0.9.3
iconfont-preview stx 0.0.5
tabnine-vscode Tab 3.72.0
pdf tom 1.2.2
vscode-workspace-explorer tom 1.5.0
intellicode-api-usage-examples Vis 0.2.8
vscodeintellicode Vis 1.2.30
gistfs vsl 0.6.0
volar Vue 1.8.27
vscode-wakatime Wak 24.4.0
vscode-todo-highlight way 1.0.5
jinja who 0.0.8
vscode-import-cost wix 3.3.0
change-case wma 1.0.0
markdown-all-in-one yzh 3.6.2
json Zai 2.0.2
vue znc 0.12.0

(3 theme extensions excluded)

A/B Experiments
vsliv368cf:30146710
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscoreces:30445986
vscod805:30301674
binariesv615:30325510
vsaa593:30376534
py29gd2263:30899288
c4g48928:30535728
azure-dev_surveyone:30548225
2i9eh265:30646982
962ge761:30959799
pythongtdpath:30769146
welcomedialogc:30910334
pythonidxpt:30866567
pythonnoceb:30805159
asynctok:30898717
pythontestfixt:30902429
pythonregdiag2:30936856
pyreplss1:30897532
pythonmypyd1:30879173
pythoncet0:30885854
2e7ec940:30968132
pythontbext0:30879054
dsvsc016:30899300
dsvsc017:30899301
dsvsc018:30899302
pydisww1:30959800
edj9j583:30969295
7j2b6412:30969109

@vscodenpa vscodenpa added the triage-needed Needs assignment to the proper sub-team label Feb 22, 2024
@vscodenpa vscodenpa removed the triage-needed Needs assignment to the proper sub-team label Feb 22, 2024
@karrtikr karrtikr added the triage-needed Needs assignment to the proper sub-team label Feb 23, 2024
@karrtikr karrtikr transferred this issue from microsoft/vscode Feb 23, 2024
@karrtikr
Copy link

Hi @lukaszwojcik89 , can you please provide the screenshots and the debug logs which can help diagnose the issue:

  • Run Developer: Set log level command
  • Select Trace
  • Run Developer: Reload Window command
  • Provide the output:
Output for Python in the Output panel (ViewOutput, change the drop-down the upper-right of the Output panel to Python)

XXX

@karrtikr karrtikr added the experimenting Feature is part of an experiment label Feb 23, 2024
@github-actions github-actions bot added the info-needed Issue requires more information from poster label Feb 23, 2024
@lukaszwojcik89
Copy link
Author

lukaszwojcik89 commented Feb 26, 2024

Hey, thanks for the reply.
I am uploading the output logs as requested. I'm also attaching one screenshot on which you can see that contrary to what is in the output ( there is information regarding the activation of the environment), the list of used Python versions does not display the correct interpreter. The pip list command also does not display the correct packages installed in the project. I also managed to take a screenshot of the non-upgraded version and there, for comparison, it looks like the second screenshot. (I'm also attaching the second log from the version where everything activated correctly).

actual logs + screenshot:
Python.log
obraz


correct version logs + screeshot:
Python — correct copy.log
obraz

@github-actions github-actions bot removed the info-needed Issue requires more information from poster label Feb 26, 2024
@karrtikr
Copy link

Closing in favor of #22910. You seem to be using Git bash which isn't officially supported by the Python extension, please try switching your default shell as instructed in the other issue, also try pre-release.

@karrtikr karrtikr closed this as not planned Won't fix, can't repro, duplicate, stale Feb 26, 2024
@karrtikr karrtikr changed the title Pipenv not activating venv Pipenv not activating venv on Gitbash Feb 26, 2024
@github-actions github-actions bot added the info-needed Issue requires more information from poster label Feb 26, 2024
@lukaszwojcik89
Copy link
Author

ok, it seems to work on CMD correctly. So it is an issue with gitbash. Thanks for help!

@github-actions github-actions bot removed the info-needed Issue requires more information from poster label Feb 26, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 29, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
experimenting Feature is part of an experiment triage-needed Needs assignment to the proper sub-team
Projects
None yet
Development

No branches or pull requests

5 participants