Return an empty dict when PIPENV_DONT_LOAD_ENV is set.

Close #4851
This commit is contained in:
Frost Ming
2021-11-09 21:48:56 +08:00
parent 9cafc59188
commit 2dfdf2a2bd
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -0,0 +1 @@
Return an empty dict when ``PIPENV_DONT_LOAD_ENV`` is set.
+1 -1
View File
@@ -2459,7 +2459,7 @@ def do_run(project, command, args, three=None, python=False, pypi_mirror=None):
)
env = os.environ.copy()
env.update(load_dot_env(project, as_dict=True))
env.update(load_dot_env(project, as_dict=True) or {})
env.pop("PIP_SHIMS_BASE_MODULE", None)
path = env.get('PATH', '')