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

Wrap around an external Python binary #1520

Open
tjni opened this issue Oct 12, 2024 · 4 comments
Open

Wrap around an external Python binary #1520

tjni opened this issue Oct 12, 2024 · 4 comments
Labels
enhancement New feature or request

Comments

@tjni
Copy link

tjni commented Oct 12, 2024

At work, we distribute Python through a non-nix mechanism. Is there a way to set devenv up to use this external Python with all the rest of the Python configuration (such as poetry, uv, etc.)?

@tjni tjni added the enhancement New feature or request label Oct 12, 2024
@domenkozar
Copy link
Member

You could override src for the python derivation if the compilation step isn't different to upstream python and then set it to languages.python.package.

@tjni
Copy link
Author

tjni commented Oct 13, 2024

In my case, the Python binary is provided by a separate team via a process I don't have much say over. (As you can imagine, there are all sorts of details that make building from source complicated: besides the team separation I just mentioned, we also develop on aarch64-darwin but distribute an x64_64-darwin Python binary, probably due to prioritizing other things.) So I'm wondering to what extent everything is tied to the Python derivation (e.g. via passthru attributes).

@tjni
Copy link
Author

tjni commented Oct 16, 2024

I looked into this a little more and immediately ran into the classic question of how can one depend on a file that's not in the Nix store in a pure way. Do you know the latest thinking on this use case upstream?

@domenkozar
Copy link
Member

It's going to be quite involved to support embedding binary python distributions. This should be doable in nixpkgs, if you need commercial support you can email [email protected] and we can look into it.

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

No branches or pull requests

2 participants