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

Unable to install pyre2 with uv #6084

Closed
sgrimee opened this issue Aug 14, 2024 · 8 comments
Closed

Unable to install pyre2 with uv #6084

sgrimee opened this issue Aug 14, 2024 · 8 comments
Assignees
Labels
needs-mre Needs more information for reproduction

Comments

@sgrimee
Copy link

sgrimee commented Aug 14, 2024

Unable to install pyre2 with uv pip, it works with pip directly.

On mac, in a nix environment with python 3.12.4 and uv 0.1.45.
Using a venv created by uv.

Trying to install pyre2:

uv pip install pyre2==0.3.6          
Resolved 1 package in 2ms
error: Failed to download distributions
  Caused by: Failed to fetch wheel: pyre2==0.3.6
  Caused by: Failed to build: `pyre2==0.3.6`
  Caused by: Build backend failed to build wheel through `build_wheel()` with exit status: 1
--- stdout:
running bdist_wheel
running build
running build_ext
-- Configuring incomplete, errors occurred!
--- stderr:
CMake Error at CMakeLists.txt:3 (project):
  Running

   '/Users/sgrimee/Library/Caches/uv/.tmpRpC52h/.venv/bin/ninja' '--version'

  failed with:

   no such file or directory

It also fails if I first install:

uv pip install ninja setuptools wheel
Resolved 3 packages in 2ms
Installed 3 packages in 11ms
 + ninja==1.11.1.1
 + setuptools==72.2.0
 + wheel==0.44.0
@charliermarsh
Copy link
Member

It looks like you might need --no-build-isolation?

@charliermarsh
Copy link
Member

@sgrimee
Copy link
Author

sgrimee commented Aug 14, 2024

Thanks for the response! So I try from a fresh venv, I install setuptools and ninja, then:

uv pip install --no-build-isolation  pyre2==0.3.6 
Resolved 1 package in 0.94ms
error: Failed to download distributions
  Caused by: Failed to fetch wheel: pyre2==0.3.6
  Caused by: Failed to build: `pyre2==0.3.6`
  Caused by: Build backend failed to build wheel through `build_wheel()` with exit status: 1
--- stdout:
running bdist_wheel
running build
running build_ext
-- Configuring incomplete, errors occurred!
--- stderr:
CMake Error at CMakeLists.txt:3 (project):
  Running

   '/Users/sgrimee/Library/Caches/uv/.tmpRpC52h/.venv/bin/ninja' '--version'

  failed with:

   no such file or directory

@charliermarsh
Copy link
Member

charliermarsh commented Aug 14, 2024

Hmm, this works as expected for me:

❯ uv venv

❯ uv pip install setuptools ninja cython

❯ uv pip install --no-build-isolation  pyre2==0.3.6
Resolved 1 package in 1ms
   Built pyre2==0.3.6
Prepared 1 package in 3.23s
Installed 1 package in 0.64ms
 + pyre2==0.3.6

@charliermarsh charliermarsh added the needs-mre Needs more information for reproduction label Aug 14, 2024
@sgrimee
Copy link
Author

sgrimee commented Aug 15, 2024

thanks for checking... are you on python 3.12?
I still see the error, and had a colleague test it to, but I see it only on 3.12.
With 3.9-11, I get another error, I think not related, which I am trying to solve also by upgrading my c++ to v17.
Would you mind sharing your python version, as well as c++ version you are using?

@charliermarsh
Copy link
Member

@sgrimee -- I just tested and it succeeds for me on both Python 3.11 and Python 3.12, unfortunately.

@charliermarsh
Copy link
Member

Gonna close due to difficulty reproducing.

@charliermarsh charliermarsh self-assigned this Sep 14, 2024
@vlcek
Copy link

vlcek commented Nov 29, 2024

Sorry for writing into an already closed issue, however, I hit the same problem with pyre2 on Python 3.11 with uv 0.5.5.
I tried the --no-build-isolation with no success, however, once I nuked the uv's cache (rm -rf ~/.cache/uv) and run uv sync again, suddenly the pyre2 build was successful.

Maybe this info will help anyone reading this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-mre Needs more information for reproduction
Projects
None yet
Development

No branches or pull requests

3 participants