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

Add Windows support #288

Open
enryH opened this issue Feb 10, 2024 · 6 comments
Open

Add Windows support #288

enryH opened this issue Feb 10, 2024 · 6 comments
Labels
upstream Bug is in a dependency of Vamb

Comments

@enryH
Copy link
Member

enryH commented Feb 10, 2024

Does installing require a rust installation?

pip install vamb
Collecting vamb
  Using cached vamb-4.1.3.tar.gz (143 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Collecting numpy==1.24.2 (from vamb)
  Downloading numpy-1.24.2-cp39-cp39-win_amd64.whl (14.9 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 14.9/14.9 MB 9.6 MB/s eta 0:00:00
Collecting torch==1.13.1 (from vamb)
  Downloading torch-1.13.1-cp39-cp39-win_amd64.whl (162.5 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 162.5/162.5 MB 4.0 MB/s eta 0:00:00
Collecting pycoverm==0.6.0 (from vamb)
  Downloading pycoverm-0.6.0.tar.gz (16 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error
  
  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [6 lines of output]
      
      Cargo, the Rust package manager, is not installed or is not on PATH.
      This package requires Rust and Cargo to compile extensions. Install it through
      the system's package manager or via https://rustup.rs/
     
      Checking for Rust toolchain....
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

Additionally: I got nowhere with a python 3.11 and then switched to 3.9

@jakobnissen
Copy link
Member

It shouldn't. Are you running Windows? It looks like the dependency has no precompiled binaries for Windows. I can try to add those.

@enryH
Copy link
Member Author

enryH commented Feb 10, 2024

I am running it on Windows, indeed. Looking at the error it might be an issue with the toml package description. Ruff is mentioned there.

vamb/pyproject.toml

Lines 39 to 40 in f37b5fd

[tool.ruff]
ignore = ["E722", "E501"]

I also go problem with the dynamic = ["version"] attribute when I try to install the latest version locally...

@enryH
Copy link
Member Author

enryH commented Feb 10, 2024

So exactly the same error for both pip install . and pip install vamb.

@enryH
Copy link
Member Author

enryH commented Feb 10, 2024

I got it now. You think it's a pycoverm issue?

So indeed:

>>> pip install pycoverm
Collecting pycoverm
  Using cached pycoverm-0.6.0.tar.gz (16 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [6 lines of output]
     
      Cargo, the Rust package manager, is not installed or is not on PATH.
      This package requires Rust and Cargo to compile extensions. Install it through
      the system's package manager or via https://rustup.rs/
     
      Checking for Rust toolchain....
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

@jakobnissen jakobnissen added the upstream Bug is in a dependency of Vamb label Feb 10, 2024
@jakobnissen
Copy link
Member

Yeah. I believe that, because there are no precompiled binaries available for pycoverm for Windows, it defaults to trying to compile it yourself. This is confusing, because the dependencies for compiling Rust is not mentioned anywhere in Vamb's dependencies.

The solution should be for pycoverm to provide binaries, if possible.

@jakobnissen jakobnissen changed the title 🐛 Rust dependency not specified Add Windows support Feb 14, 2024
@jakobnissen
Copy link
Member

For future me: Vamb transitively depends on the Rust crate rust-htslib which fails to compile on Windows.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
upstream Bug is in a dependency of Vamb
Projects
None yet
Development

No branches or pull requests

2 participants