question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

virtualenv: error: argument --creator: invalid choice: 'venv' (choose from 'builtin', 'cpython2-posix')

See original GitHub issue

Issue description

pipenv check fails or actually everything fails; it does install the python version correctly however.

Expected result

it to work, obviously 😉

Actual result

/usr/local/py-utils/venvs/pipenv/lib/python3.11/site-packages/pipenv/vendor/attr/_make.py:876: RuntimeWarning: Running interpreter doesn't sufficiently support code object introspection.  Some features like bare super() or accessing __class__ will not work with slotted classes.
  set_closure_cell(cell, cls)
/usr/local/py-utils/venvs/pipenv/lib/python3.11/site-packages/pipenv/vendor/attr/_make.py:876: RuntimeWarning: Running interpreter doesn't sufficiently support code object introspection.  Some features like bare super() or accessing __class__ will not work with slotted classes.
  set_closure_cell(cell, cls)
/usr/local/py-utils/venvs/pipenv/lib/python3.11/site-packages/pipenv/vendor/attr/_make.py:876: RuntimeWarning: Running interpreter doesn't sufficiently support code object introspection.  Some features like bare super() or accessing __class__ will not work with slotted classes.
  set_closure_cell(cell, cls)
Creating a virtualenv for this project...
Pipfile: /workspaces/backend/Pipfile
Using /home/vscode/.pyenv/versions/2.7.18/bin/python2.7 (2.7.18) to create virtualenv...
⠙ Creating virtual environment...SystemExit: 2

✘ Failed creating virtual environment 
[pipenv.exceptions.VirtualenvCreationException]: usage: virtualenv [--version] [--with-traceback] [-v | -q] [--read-only-app-data] [--app-data APP_DATA] [--reset-app-data] [--upgrade-embed-wheels] [--discovery {builtin}] [-p py] [--try-first-with py_exe]
                  [--creator {builtin,cpython2-posix}] [--seeder {app-data,pip}] [--no-seed] [--activators comma_sep_list]
virtualenv: error: argument --creator: invalid choice: 'venv' (choose from 'builtin', 'cpython2-posix')

Failed to create virtual environment.

When possible, provide the verbose output (--verbose), especially for locking and dependencies resolving issues.

Steps to replicate

Provide the steps to replicate (which usually at least includes the commands and the Pipfile).

Pipfile:

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

pipenv check already fails


Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:8

github_iconTop GitHub Comments

1reaction
iamdbychkovcommented, Dec 6, 2022

May I Bring this up again?

Having the same issue using 3.10.6. removing virtualenv installed from apt made no difference.

pipx installations and bare pip installation behave the same.

Figured out it’s not working for python2 installs via: pipenv --python 2.7.18 Guess there was some change which made it unavailable. Will post an update as soon as I check the version of pipenv which I use on another computer to create venvs.

1reaction
matteiuscommented, Nov 2, 2022

@f0o We don’t have support for python 3.11 yet

Read more comments on GitHub >

github_iconTop Results From Across the Web

"virtualenv: error: argument --creator: invalid choice: 'venv ...
I tried using the pipenv Environment and got this error "irtualenv: error: argument --creator: invalid choice: 'venv' (choose from ...
Read more >
I am unable to create a new virtualenv in ubuntu?
I got the error while updating dependencies with poetry. Uninstalling virtualenv package that was present in the venv (probably as subdependency ...
Read more >
venv — Creation of virtual environments
Source code: Lib/venv/ The venv module supports creating lightweight “virtual ... an error was raised, unless the --clear or --upgrade option was provided....
Read more >
virtualenv - Python virtual environment creator
The virtualenv utility creates virtual Python instances, each invokable with its own ... options for creator builtin --creator {builtin,cpython3-posix,venv} ...
Read more >
virtualenv(1) — Arch manual pages
Since Python 3.3, a subset of it has been integrated into the standard library under the venv module. The venv module does not...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found