Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Setting pipenv environment variable in venv

I am trying to set up a Python virtual environment with pipenv. In VS Code, started in a fresh directory of Windows 10 OS, after doing:

  1. python -m venv work_env in the Terminal
  2. Noting the path of the Script folder within work_env
  3. Doing Ctrl-Shift-P and Preferences: Open Workspace Settings
  4. In settings.json, adding:
  • environment path of Step 2 to "python.pythonPath":
  • folder names to prevent pylance yellow squigglies to "python.analysis.extraPaths":
  1. Doing a pipenv install in the Terminal
  2. Updating package names in Pipfile
  3. Doing pipenv update in the Terminal

... There comes a Courtesy Notice: Pipenv found itself running within a virtual environment, ... You can set PIPENV_VERBOSITY=-1 to suppress this warning.

In what folder / file / configuration do I set this PIPENV_VERBOSITY=-1 ?

like image 329
reservoirinvest Avatar asked Jan 27 '26 02:01

reservoirinvest


1 Answers

  1. According to the information you provided, I reproduced the problem you described:

    enter image description here

  2. The reason is as this 'Courtesy Notice', "pipenv install" is to create a virtual environment for the current project, and we have created a virtual environment "work_env", so it prompts us to ignore this environment or Suppress this warning.

  3. We can directly enter the command "set PIPENV_VERBOSITY=-1" in the console to suppress this warning:

    enter image description here

    After:

    enter image description here

The pipenv version I use is 2020.11.4.

Update:

enter image description here

like image 175
Jill Cheng Avatar answered Jan 29 '26 16:01

Jill Cheng



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!