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

2020.6.2 breaks if .venv directory already exists #4324

Closed
gsemet opened this issue Jun 6, 2020 · 4 comments
Closed

2020.6.2 breaks if .venv directory already exists #4324

gsemet opened this issue Jun 6, 2020 · 4 comments
Labels
Status: Awaiting Update ⏳ This issue requires more information before assistance can be provided. Status: Needs More Information This issue does not provide enough information to take further action. Type: Duplicate This issue is a duplicate of an already-existing issue.

Comments

@gsemet
Copy link
Contributor

gsemet commented Jun 6, 2020

With 2020.5.28 I have the right behavior, similar to the previous versions of pipenv: if an empty .venv directory exists prior to the first execution of pipenv install or pipen --rm, it behaves like when the environment variable PIPENV_VENV_IN_PROJECT=1 is set.

With 2020.6.2, I have the following error:

Courtesy Notice: Pipenv found itself running within a virtual environment, so it will automatically use that environment, instead of creating its own for any project. You can set PIPENV_IGNORE_VIRTUALENVS=1 to force pipenv to ignore that environment and create its own instead. You can set PIPENV_VERBOSITY=-1 to suppress this warning.
Warning: There was an unexpected error while activating your virtualenv. Continuing anyway...

Ideally, a setting in the Pipfile would be great:

[[pipenv]]
venv_in_project=1
...

$ pipenv --support

Pipenv version: '2020.6.2'

Pipenv location: '/usr/local/lib/python3.7/site-packages/pipenv'

Python location: '/usr/local/opt/python/bin/python3.7'

Python installations found:

  • 3.7.7: /usr/local/bin/python3
  • 3.7.7: /usr/local/bin/python3.7m
  • 3.7.7: /usr/local/bin/python3.7
  • 3.7.7: /Users/myusername/.pyenv/versions/3.7.7/bin/python3
  • 3.7.6: /Users/myusername/.pyenv/versions/3.7.6/bin/python3
  • 3.7.5: /Users/myusername/.pyenv/versions/3.7.5/bin/python3
  • 3.7.4: /Users/myusername/.pyenv/versions/3.7.4/bin/python3
  • 3.7.3: /Users/myusername/.pyenv/versions/3.7.3/bin/python3
  • 3.6.10: /Users/myusername/.pyenv/versions/3.6.10/bin/python3
  • 3.6.9: /Users/myusername/.pyenv/versions/3.6-dev/bin/python3
  • 3.6.9: /Users/myusername/.pyenv/versions/3.6.9/bin/python3
  • 3.5.9: /Users/myusername/.pyenv/versions/3.5.9/bin/python3
  • 3.5.7: /Users/myusername/.pyenv/versions/3.5.7/bin/python3
  • 2.7.16: /usr/bin/python2.7

PEP 508 Information:

{'implementation_name': 'cpython',
 'implementation_version': '3.7.7',
 'os_name': 'posix',
 'platform_machine': 'x86_64',
 'platform_python_implementation': 'CPython',
 'platform_release': '18.7.0',
 'platform_system': 'Darwin',
 'platform_version': 'Darwin Kernel Version 18.7.0: Mon Feb 10 21:08:45 PST '
                     '2020; root:xnu-4903.278.28~1/RELEASE_X86_64',
 'python_full_version': '3.7.7',
 'python_version': '3.7',
 'sys_platform': 'darwin'}

System environment variables:

  • TERM_PROGRAM
  • PYENV_ROOT
  • PIPENV_PYTHON
  • ASDF_DIR
  • TERM
  • SHELL
  • TMPDIR
  • Apple_PubSub_Socket_Render
  • TERM_PROGRAM_VERSION
  • TERM_SESSION_ID
  • PYENV_VERSION
  • LC_ALL
  • NO_PROXY
  • http_proxy
  • USER
  • COMMAND_MODE
  • SSH_AUTH_SOCK
  • PYENV_DIR
  • __CF_USER_TEXT_ENCODING
  • PAGER
  • LSCOLORS
  • PATH
  • MARKPATH
  • PWD
  • EDITOR
  • LANG
  • ITERM_PROFILE
  • PYENV_HOOK_PATH
  • XPC_FLAGS
  • HTTPS_PROXY
  • https_proxy
  • XPC_SERVICE_NAME
  • PYENV_SHELL
  • SHLVL
  • HOME
  • COLORFGBG
  • __no_proxy
  • LC_TERMINAL_VERSION
  • no_proxy
  • __proxy_url
  • HTTP_PROXY
  • ITERM_SESSION_ID
  • LESS
  • LOGNAME
  • LC_CTYPE
  • PKG_CONFIG_PATH
  • LC_TERMINAL
  • SECURITYSESSIONID
  • COLORTERM
  • PIP_DISABLE_PIP_VERSION_CHECK
  • PYTHONDONTWRITEBYTECODE
  • PIP_SHIMS_BASE_MODULE
  • PIP_PYTHON_PATH
  • PYTHONFINDER_IGNORE_UNSUPPORTED

Pipenv–specific environment variables:

  • PIPENV_PYTHON: /Users/myusername/.pyenv/shims/python

Debug–specific environment variables:

  • PATH: /usr/local/Cellar/pyenv/1.2.18/libexec:/usr/local/sbin:/Users/myusername/bin:/Users/myusername/.local/bin:/usr/local/lib/ruby/gems/2.6.0/bin:/usr/local/opt/node@12/bin:/usr/local/opt/postgresql@10/bin:/usr/local/opt/ruby/bin:/Users/myusername/Library/Python/3.7/bin:/Users/myusername/.pyenv/shims:/usr/local/opt/gettext/bin:/usr/local/bin:/Users/myusername/bin:/Users/myusername/.pyenv/shims:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/myusername/.rvm/bin
  • SHELL: /bin/zsh
  • EDITOR: vim
  • LANG: en_US.UTF-8
  • PWD: /Users/myusername/Projects/Alton/cookiecutter-python-module

Contents of Pipfile ('/Users/myusername/Projects/Alton/cookiecutter-python-module/Pipfile'):

[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true

[dev-packages]

[packages]

[requires]
python_version = "3.7"
@frostming
Copy link
Contributor

Can you fill the issue template with pipenv --support output? Are you on MacOS?

@frostming frostming added Status: Awaiting Update ⏳ This issue requires more information before assistance can be provided. Status: Needs More Information This issue does not provide enough information to take further action. labels Jun 6, 2020
@gsemet
Copy link
Contributor Author

gsemet commented Jun 6, 2020

Indeed, Mac 10.14.6. I update the bug report

@frostming
Copy link
Contributor

Duplicated, see #4327 and #4316

@frostming frostming added the Type: Duplicate This issue is a duplicate of an already-existing issue. label Jun 9, 2020
@Kevinoh47
Copy link

um... it looks like you closed ALL of the related issues as duplicate. At least I can't find one that isn't closed as duplicate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Awaiting Update ⏳ This issue requires more information before assistance can be provided. Status: Needs More Information This issue does not provide enough information to take further action. Type: Duplicate This issue is a duplicate of an already-existing issue.
Projects
None yet
Development

No branches or pull requests

3 participants