Closed chrisroat closed 1 month ago
When executing a pipenv shell the internal function load_dot_env is called in both the cli and shell functions.
pipenv shell
Note that in the shell call, load_dot_env is not passed the state.quiet argument.
shell
load_dot_env
state.quiet
The function is called only once in the cli function with the quiet option.
cli
$ pipenv shell Loading .env environment variables... Loading .env environment variables... Launching subshell in virtual environment... ...
$ pipenv --quiet shell Loading .env environment variables... Launching subshell in virtual environment... ...
No Pipfile necessary -- just run pipenv.
Pipfile
pipenv
$ pipenv shell Loading .env environment variables... Launching subshell in virtual environment... ...
$ pipenv --quiet shell Launching subshell in virtual environment... ...
Would simply removing the load_dot_env call in shell be acceptable?
Issue description
When executing a
pipenv shell
the internal function load_dot_env is called in both the cli and shell functions.Note that in the
shell
call,load_dot_env
is not passed thestate.quiet
argument.Expected result
The function is called only once in the
cli
function with the quiet option.Actual result
Steps to replicate
No
Pipfile
necessary -- just runpipenv
.$ pipenv --support
Pipenv version: `'2024.0.1'` Pipenv location: `'/opt/homebrew/Cellar/pipenv/2024.0.1/libexec/lib/python3.12/site-packages/pipenv'` Python location: `'/opt/homebrew/Cellar/pipenv/2024.0.1/libexec/bin/python'` OS Name: `'posix'` User pip version: `'24.0'` user Python installations found: PEP 508 Information: ``` {'implementation_name': 'cpython', 'implementation_version': '3.12.4', 'os_name': 'posix', 'platform_machine': 'arm64', 'platform_python_implementation': 'CPython', 'platform_release': '23.5.0', 'platform_system': 'Darwin', 'platform_version': 'Darwin Kernel Version 23.5.0: Wed May 1 20:19:05 PDT ' '2024; root:xnu-10063.121.3~5/RELEASE_ARM64_T8112', 'python_full_version': '3.12.4', 'python_version': '3.12', 'sys_platform': 'darwin'} ``` System environment variables: - `TERM_PROGRAM` - `SHELL` - `TERM` - `TMPDIR` - `TERM_PROGRAM_VERSION` - `TERM_SESSION_ID` - `USER` - `SSH_AUTH_SOCK` - `PATH` - `__CFBundleIdentifier` - `PWD` - `XPC_FLAGS` - `XPC_SERVICE_NAME` - `SHLVL` - `HOME` - `LOGNAME` - `OLDPWD` - `HOMEBREW_PREFIX` - `HOMEBREW_CELLAR` - `HOMEBREW_REPOSITORY` - `MANPATH` - `INFOPATH` - `ZSH` - `PAGER` - `LESS` - `LSCOLORS` - `LS_COLORS` - `VIRTUAL_ENV_DISABLE_PROMPT` - `__CF_USER_TEXT_ENCODING` - `PIP_DISABLE_PIP_VERSION_CHECK` - `PYTHONDONTWRITEBYTECODE` - `PIP_PYTHON_PATH` - `PIPENV_ACTIVE` - `VIRTUAL_ENV` - `VIRTUAL_ENV_PROMPT` - `LANG` - `_` - `PYTHONFINDER_IGNORE_UNSUPPORTED` Pipenv–specific environment variables: - `PIPENV_ACTIVE`: `1` Debug–specific environment variables: - `PATH`: `/Users/chrisroat/.local/share/virtualenvs/test-jfMfHFml/bin:/Users/chrisroat/development/flutter/bin:/Applications/Postgres.app/Contents/Versions/16/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/Library/Apple/usr/bin:/Users/chrisroat/development/flutter/bin:/Applications/Postgres.app/Contents/Versions/16/bin:/opt/homebrew/bin:/opt/homebrew/sbin` - `SHELL`: `/bin/zsh` - `LANG`: `en_US.UTF-8` - `PWD`: `/Users/chrisroat/test` - `VIRTUAL_ENV`: `/Users/chrisroat/.local/share/virtualenvs/test-jfMfHFml` --------------------------- Contents of `Pipfile` ('/Users/chrisroat/test/Pipfile'): ```toml [[source]] url = "https://pypi.org/simple" verify_ssl = true name = "pypi" [packages] [dev-packages] [requires] python_version = "3.12" ```