pipenv: Pipenv failed to build wheels (PEP 517)

Given the following:

$ python3 -V
Python 3.9.1

$ pipenv --version
pipenv, version 2020.11.15

$ pip --version
pip 20.3.3

Let us consider mkdir test && cd test the following minimal Pipfile

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

[packages]
pandas = "*"

Running a simple pipenv install generates a mile long error message whose last bits are

  ...
  ----------------------------------------
  ERROR: Failed building wheel for numpy
Failed to build numpy
ERROR: Could not build wheels for numpy which use PEP 517 and cannot be installed directly
...
...
pipenv.patched.notpip._internal.exceptions.InstallationError: Command errored out with exit status 1: /~/.local/share/virtualenvs/test-mmObi3rW/bin/python /usr/local/lib/python3.9/site-packages/pipenv/patched/notpip install --ignore-installed --no-user --prefix /private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-build-env-lje2m4uc/overlay --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- setuptools wheel 'Cython>=0.29.21,<3' 'numpy==1.15.4; python_version=='"'"'3.6'"'"' and platform_system!='"'"'AIX'"'"'' 'numpy==1.15.4; python_version=='"'"'3.7'"'"' and platform_system!='"'"'AIX'"'"'' 'numpy==1.17.3; python_version=='"'"'3.8'"'"' and platform_system!='"'"'AIX'"'"'' 'numpy==1.16.0; python_version=='"'"'3.6'"'"' and platform_system=='"'"'AIX'"'"'' 'numpy==1.16.0; python_version=='"'"'3.7'"'"' and platform_system=='"'"'AIX'"'"'' 'numpy==1.17.3; python_version=='"'"'3.8'"'"' and platform_system=='"'"'AIX'"'"'' 'numpy; python_version>='"'"'3.9'"'"'' Check the logs for full command output.

This problem has been touched already for instance here, here and here concering pip. Apparently the suggestion is to explicitly include the flag --no-use-pep517 which however does not work in conjunction with pipenv, producing pipenv.vendor.requirementslib.exceptions.RequirementError: Failed parsing requirement from '--no-use-pep517'.

It seems there is also a general problem with the version 2020.11.15, I do not exactly understand whether related or not. If instead of pandas one installs pipenv install request (or any other package not containing particular dependencies) the installation works fine, which makes me think the problem is indeed the building of the numpy wheels.

What is the right procedure in this case to just proceed with the installation?


$ pipenv --support

Pipenv version: '2020.11.15'

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

Python location: '/usr/local/opt/python@3.9/bin/python3.9'

Python installations found:

  • 3.9.1: ~/.local/share/virtualenvs/test-mmObi3rW/bin/python3
  • 3.9.1: ~/.local/share/virtualenvs/test-mmObi3rW/bin/python3.9
  • 3.9.1: ~/.local/share/virtualenvs/test-mmObi3rW/bin/python3
  • 3.9.1: ~/.local/share/virtualenvs/test-mmObi3rW/bin/python3.9
  • 3.9.1: /usr/local/bin/python3
  • 3.9.1: /usr/local/bin/python3.9
  • 3.8.2: /usr/bin/python3
  • 2.7.16: /usr/bin/python2
  • 2.7.16: /usr/bin/python2.7

PEP 508 Information:

{'implementation_name': 'cpython',
 'implementation_version': '3.9.1',
 'os_name': 'posix',
 'platform_machine': 'x86_64',
 'platform_python_implementation': 'CPython',
 'platform_release': '20.2.0',
 'platform_system': 'Darwin',
 'platform_version': 'Darwin Kernel Version 20.2.0: Wed Dec  2 20:39:59 PST '
                     '2020; root:xnu-7195.60.75~1/RELEASE_X86_64',
 'python_full_version': '3.9.1',
 'python_version': '3.9',
 'sys_platform': 'darwin'}

System environment variables:

  • TERM_SESSION_ID
  • SSH_AUTH_SOCK
  • LC_TERMINAL_VERSION
  • COLORFGBG
  • ITERM_PROFILE
  • XPC_FLAGS
  • PWD
  • SHELL
  • __CFBundleIdentifier
  • LC_CTYPE
  • TERM_PROGRAM_VERSION
  • TERM_PROGRAM
  • PATH
  • LC_TERMINAL
  • COLORTERM
  • COMMAND_MODE
  • TERM
  • HOME
  • TMPDIR
  • USER
  • XPC_SERVICE_NAME
  • LOGNAME
  • ITERM_SESSION_ID
  • __CF_USER_TEXT_ENCODING
  • SHLVL
  • OLDPWD
  • P9K_TTY
  • ZSH
  • PAGER
  • LESS
  • LSCOLORS
  • P9K_SSH
  • EDITOR
  • LANG
  • MANPAGER
  • FZF_DEFAULT_OPTS
  • FZF_DEFAULT_COMMAND
  • PIP_DISABLE_PIP_VERSION_CHECK
  • PYTHONDONTWRITEBYTECODE
  • PIP_PYTHON_PATH
  • PIPENV_ACTIVE
  • VIRTUAL_ENV
  • PS1
  • _
  • PIP_SHIMS_BASE_MODULE
  • PYTHONFINDER_IGNORE_UNSUPPORTED

Pipenv–specific environment variables:

  • PIPENV_ACTIVE: 1

Debug–specific environment variables:

  • PATH: ~/.local/share/virtualenvs/test-mmObi3rW/bin:~/.cargo/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/usr/local/MacGPG2/bin:/usr/local/opt/fzf/bin
  • SHELL: /bin/zsh
  • EDITOR: vim
  • LANG: en_US.UTF-8
  • PWD: ~/test
  • VIRTUAL_ENV: ~/.local/share/virtualenvs/test-mmObi3rW

Contents of Pipfile (‘~/test/Pipfile’):

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

[packages]
pandas = "*"

About this issue

  • Original URL
  • State: closed
  • Created 4 years ago
  • Reactions: 21
  • Comments: 47 (8 by maintainers)

Most upvoted comments

Can you install it via pipenv run pip install --no-use-pep517 numpy?

doing so produces the same error stated above, whose complete stacktrace is

Failed to build numpy
Installing collected packages: numpy
    Running setup.py install for numpy ... error
    ERROR: Command errored out with exit status 1:
     command: ~/.local/share/virtualenvs/test-mmObi3rW/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/setup.py'"'"'; __file__='"'"'/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-record-agkzau_0/install-record.txt --single-version-externally-managed --compile --install-headers /Users/gennarotedesco/.local/share/virtualenvs/test-mmObi3rW/include/site/python3.9/numpy
         cwd: /private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/
    Complete output (41 lines):
    Running from numpy source directory.

    Note: if you need reliable uninstall behavior, then install
    with pip instead of using `setup.py install`:

      - `pip install .`       (from a git repo or downloaded source
                               release)
      - `pip install numpy`   (last NumPy release on PyPi)


    Cythonizing sources
    numpy/random/_bounded_integers.pxd.in has not changed
    Processing numpy/random/_philox.pyx
    Traceback (most recent call last):
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/tools/cythonize.py", line 59, in process_pyx
        from Cython.Compiler.Version import version as cython_version
    ModuleNotFoundError: No module named 'Cython'

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/tools/cythonize.py", line 235, in <module>
        main()
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/tools/cythonize.py", line 231, in main
        find_process_files(root_dir)
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/tools/cythonize.py", line 222, in find_process_files
        process(root_dir, fromfile, tofile, function, hash_db)
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/tools/cythonize.py", line 188, in process
        processor_function(fromfile, tofile)
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/tools/cythonize.py", line 64, in process_pyx
        raise OSError('Cython needs to be installed in Python as a module')
    OSError: Cython needs to be installed in Python as a module
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/setup.py", line 508, in <module>
        setup_package()
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/setup.py", line 488, in setup_package
        generate_cython()
      File "/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/setup.py", line 285, in generate_cython
        raise RuntimeError("Running cythonize failed!")
    RuntimeError: Running cythonize failed!
    ----------------------------------------
ERROR: Command errored out with exit status 1: ~/.local/share/virtualenvs/test-mmObi3rW/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/setup.py'"'"'; __file__='"'"'/private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-install-r4nvpr4k/numpy/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/vw/67twknb114j86_qdm17qgrk40000gn/T/pip-record-agkzau_0/install-record.txt --single-version-externally-managed --compile --install-headers ~/.local/share/virtualenvs/test-mmObi3rW/include/site/python3.9/numpy Check the logs for full command output.

Looking around some more on the internet I managed to make it work by means of the mysterious and obscure command export SYSTEM_VERSION_COMPAT=1, found somehow accidentally here.

–no-use-pep517 is not the correct path to resolving the issue, Pip will also remove the support in the future

What then exactly is the solution to the problem? More generally, is pipenv keeping up with pip and python updates and versionings? If so, there must be a way to install packages without having to perform workarounds as above, must it not?

(Slightly OT please forgive the noise. For those finding this thread looking for numpy/scipy solutions)

As of 4th August 2021 with a M1 Macbook Pro with Big Sur v11.4 (20F71) Python 3.9.6 (Homebrew):

Numpy just works (installs numpy v1.21.1):

pip install numpy

Scipy works with a combination of build flags and and libraries from homebrew (installs scipy v1.7.0):

brew install openblas
export OPENBLAS=$(brew --prefix openblas)
export CFLAGS="-falign-functions=8 ${CFLAGS}"
pip install Cython pybind11 pythran
pip install --no-use-pep517 scipy

Apologies for being critical, but this is obviously not being looked at/fixed (6 months is a somewhat obscene amount of time for such an urgent case). At this point it would be great to even just have a confirmation from the development team that users ought to move away from pipenv (frankly I cannot just continue checking this thread every day or hack all sorts of workaround in production code).

I taught a pandas related MOOC last week, where I guided more than 75 students through installation with pipenv. This error, which was entirely new to me, was encountered by numerous members of the class. Thank you to everyone working on a fix. I can assure it will be appreciated by many.

Can you show the full error message of pipenv install --verbose?

Looking around some more on the internet I managed to make it work by means of the mysterious and obscure command export SYSTEM_VERSION_COMPAT=1

Yes, it does the trick by pretending the OS version to be macOS 10, which has a pre-built wheel on PyPI.

The workaround has worked for me on MacOS 11.2.3 which I have just installed/updated to.

I’m on 11.2 with ARM64 and the workaround does NOT work here.

  1. installing pandas hangs with pipenv install pandas
  2. Installing numpy crashes using the same cannot build wheels fault.

Is there a fix for this? I tried export SYSTEM_VERSION_COMPAT=1 but get error

########### CLIB COMPILER OPTIMIZATION ########### Platform : Architecture: aarch64 Compiler : clang

CPU baseline : Requested : ‘min’ Enabled : NEON NEON_FP16 NEON_VFPV4 ASIMD Flags : none Extra checks: none

CPU dispatch : Requested : ‘max -xop -fma4’ Enabled : ASIMDHP ASIMDDP Generated : none CCompilerOpt._cache_write[796] : write cache to path -> /private/var/folders/lf/2v_lshfd6411zrk07w4_kf2c0000gn/T/pip-install-345t8gh2/numpy/build/temp.macosx-11-arm64-3.9/ccompiler_opt_cache_clib.py

ERROR: Failed building wheel for numpy ERROR: Could not build wheels for numpy which use PEP 517 and cannot be installed directly

I am on new MacBook with M1 processor. I installed pipenv through brew. Appreciate the help!

(Slightly OT please forgive the noise. For those finding this thread looking for numpy/scipy solutions)

As of 4th August 2021 with a M1 Macbook Pro with Big Sur v11.4 (20F71) Python 3.9.6 (Homebrew):

Numpy just works (installs numpy v1.21.1):

pip install numpy

Scipy works with a combination of build flags and and libraries from homebrew (installs scipy v1.7.0):

brew install openblas
export OPENBLAS=$(brew --prefix openblas)
export CFLAGS="-falign-functions=8 ${CFLAGS}"
pip install Cython pybind11 pythran
pip install --no-use-pep517 scipy

As of September 27th 2021, there is no need to include pythran nor add the --no-use-pep517 argument. pip install scipy works, as well as pip install scikit-learn that had the same issue as SciPy

Still have this issue in the latest release. Failed when locking.

I am running into the same issues. Can’t install pandas using pipenv. I get the following:

> pipenv run pip install --no-use-pep517 pandas
Loading .env environment variables...
Collecting pandas
  Downloading pandas-1.2.4.tar.gz (5.5 MB)
     |████████████████████████████████| 5.5 MB 873 kB/s 
    ERROR: Command errored out with exit status 1:
     command: /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/pandas_fecb06468ee1462a8010f89dc0c5b2bd/setup.py'"'"'; __file__='"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/pandas_fecb06468ee1462a8010f89dc0c5b2bd/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-pip-egg-info-3f6hcjq1
         cwd: /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/pandas_fecb06468ee1462a8010f89dc0c5b2bd/
    Complete output (5 lines):
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/pandas_fecb06468ee1462a8010f89dc0c5b2bd/setup.py", line 20, in <module>
        import numpy
    ModuleNotFoundError: No module named 'numpy'
    ----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/e8/81/f7be049fe887865200a0450b137f2c574647b9154503865502cfd720ab5d/pandas-1.2.4.tar.gz#sha256=649ecab692fade3cbfcf967ff936496b0cfba0af00a55dfaacd82bdda5cb2279 (from https://pypi.org/simple/pandas/) (requires-python:>=3.7.1). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
  Using cached pandas-1.2.3-cp39-cp39-macosx_11_0_arm64.whl
Collecting python-dateutil>=2.7.3
  Using cached python_dateutil-2.8.1-py2.py3-none-any.whl (227 kB)
Collecting pytz>=2017.3
  Using cached pytz-2021.1-py2.py3-none-any.whl (510 kB)
Collecting numpy>=1.16.5
  Downloading numpy-1.20.2.zip (7.8 MB)
     |████████████████████████████████| 7.8 MB 51.6 MB/s 
Requirement already satisfied: six>=1.5 in /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/lib/python3.9/site-packages (from python-dateutil>=2.7.3->pandas) (1.15.0)
Building wheels for collected packages: numpy
  Building wheel for numpy (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"'; __file__='"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-wheel-1xmcy8ow
       cwd: /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/
  Complete output (32 lines):
  Running from numpy source directory.
  Cythonizing sources
  Processing numpy/random/_bounded_integers.pxd.in
  Processing numpy/random/_philox.pyx
  Traceback (most recent call last):
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 59, in process_pyx
      from Cython.Compiler.Version import version as cython_version
  ModuleNotFoundError: No module named 'Cython'
  
  During handling of the above exception, another exception occurred:
  
  Traceback (most recent call last):
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 235, in <module>
      main()
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 231, in main
      find_process_files(root_dir)
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 222, in find_process_files
      process(root_dir, fromfile, tofile, function, hash_db)
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 188, in process
      processor_function(fromfile, tofile)
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 64, in process_pyx
      raise OSError('Cython needs to be installed in Python as a module')
  OSError: Cython needs to be installed in Python as a module
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py", line 513, in <module>
      setup_package()
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py", line 493, in setup_package
      generate_cython()
    File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py", line 290, in generate_cython
      raise RuntimeError("Running cythonize failed!")
  RuntimeError: Running cythonize failed!
  ----------------------------------------
  ERROR: Failed building wheel for numpy
  Running setup.py clean for numpy
  ERROR: Command errored out with exit status 1:
   command: /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"'; __file__='"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' clean --all
       cwd: /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0
  Complete output (10 lines):
  Running from numpy source directory.
  
  `setup.py clean` is not supported, use one of the following instead:
  
    - `git clean -xdf` (cleans all files)
    - `git clean -Xdf` (cleans all versioned files, doesn't touch
                        files that aren't checked into the git repo)
  
  Add `--force` to your command to use it anyway if you must (unsupported).
  
  ----------------------------------------
  ERROR: Failed cleaning build dir for numpy
Failed to build numpy
Installing collected packages: pytz, python-dateutil, numpy, pandas
    Running setup.py install for numpy ... error
    ERROR: Command errored out with exit status 1:
     command: /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"'; __file__='"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-record-4t7otijb/install-record.txt --single-version-externally-managed --compile --install-headers /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/include/site/python3.9/numpy
         cwd: /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/
    Complete output (41 lines):
    Running from numpy source directory.
    
    Note: if you need reliable uninstall behavior, then install
    with pip instead of using `setup.py install`:
    
      - `pip install .`       (from a git repo or downloaded source
                               release)
      - `pip install numpy`   (last NumPy release on PyPi)
    
    
    Cythonizing sources
    numpy/random/_bounded_integers.pxd.in has not changed
    Processing numpy/random/_philox.pyx
    Traceback (most recent call last):
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 59, in process_pyx
        from Cython.Compiler.Version import version as cython_version
    ModuleNotFoundError: No module named 'Cython'
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 235, in <module>
        main()
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 231, in main
        find_process_files(root_dir)
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 222, in find_process_files
        process(root_dir, fromfile, tofile, function, hash_db)
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 188, in process
        processor_function(fromfile, tofile)
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/tools/cythonize.py", line 64, in process_pyx
        raise OSError('Cython needs to be installed in Python as a module')
    OSError: Cython needs to be installed in Python as a module
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py", line 513, in <module>
        setup_package()
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py", line 493, in setup_package
        generate_cython()
      File "/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py", line 290, in generate_cython
        raise RuntimeError("Running cythonize failed!")
    RuntimeError: Running cythonize failed!
    ----------------------------------------
ERROR: Command errored out with exit status 1: /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"'; __file__='"'"'/private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-install-bqphdnyh/numpy_217288709a414f079621a5af52b213b0/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /private/var/folders/45/6dwwgy2x13166tqq3598sk280000gn/T/pip-record-4t7otijb/install-record.txt --single-version-externally-managed --compile --install-headers /Users/paul/.local/share/virtualenvs/hcp365_dashboard-iyCyyTy3/include/site/python3.9/numpy Check the logs for full command output.

I can install and have installed pandas via pip and can use this…But when trying to use a pipenv environment it just hangs.

I ran into wheel discovery issues with vanilla pip install as well.

I followed advice here, which suggested upgrading pip itself: https://github.com/scipy/scipy/issues/13102#issuecomment-737009648

After upgradingpip to the 21.0.1, release, installing the same packages went fine. Running pip install allowed me to install pandas/numpy/scipy using wheel distributions (and without having to compile).

However, running pipenv install still ran into the same issues (not finding wheels), despite the fact that it was apparently using the up-to-date pip release.

I’m not understanding why y’all can’t use the workaround. At least post up the error your getting image