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

[Bug] Error when adding Git repos #2730

Open
2 tasks done
T145 opened this issue Dec 18, 2024 · 3 comments
Open
2 tasks done

[Bug] Error when adding Git repos #2730

T145 opened this issue Dec 18, 2024 · 3 comments

Comments

@T145
Copy link

T145 commented Dec 18, 2024

Checks

  • I have checked that this issue has not already been reported.

  • I have confirmed this bug exists on the latest version of pixi, using pixi --version.

Reproducible example

PS C:\Users\anon\Desktop\aida> pixi add --pypi llm-reader@git+https://github.com/m92vyas/llm-reader.git
  × failed to solve the pypi requirements of 'default' 'win-64'
  ├─▶ Failed to download and build `llm-reader @ git+https://github.com/m92vyas/llm-reader.git`
  ╰─▶ Build backend failed to determine requirements with `build_wheel()` (exit code: 1)
      
      [stderr]
      Traceback (most recent call last):
        File "<string>", line 8, in <module>
        File "C:\Users\anon\AppData\Local\rattler\cache\uv-cache\builds-v0\.tmpFgn78P\Lib\site-packages\setuptools\__init__.py", line 27, in <module>
          from .dist import Distribution
        File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
        File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
        File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
        File "C:\Users\anon\AppData\Local\rattler\cache\uv-cache\builds-v0\.tmpFgn78P\Lib\site-packages\_virtualenv.py", line 89, in exec_module
          old(module)
        File "C:\Users\anon\AppData\Local\rattler\cache\uv-cache\builds-v0\.tmpFgn78P\Lib\site-packages\setuptools\dist.py", line 27, in <module>
          from .config import pyprojecttoml, setupcfg
      SyntaxError: source code string cannot contain null bytes

Issue description

This never happened before updating to the latest Pixi version, but now Git repos break.

Expected behavior

The Git repo is added and built successfully as on older versions.

@ruben-arts
Copy link
Contributor

@nichmor would you be able to take a look at this, as you have working on our other git work?

@nichmor
Copy link
Contributor

nichmor commented Dec 24, 2024

hey @T145! thanks for reporting this!

I tried to reproduce it on osx-arm64, and unfortunately it works for me.

I've asked my colegue @ruben-arts to try it on windows machine ( as I see from your logs you are using it for win ). will return with details

@ruben-arts
Copy link
Contributor

Hey, I just tried. This works for me on win-64 too:

[project]
channels = ["conda-forge"]
name = "llm-reader"
platforms = ["win-64"]
version = "0.1.0"

[dependencies]
python = "==3.12"

[pypi-dependencies]
llm-reader = { git = "https://github.com/m92vyas/llm-reader.git" }

Maybe you've got a corrupted cache. Running a pixi clean cache --pypi might help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants