pypi2nix icon indicating copy to clipboard operation
pypi2nix copied to clipboard

Does not create executables?

Open turion opened this issue 4 years ago • 5 comments

I tried:

$ pypi2nix -e csvdiff
$ nix-shell requirements.nix -A interpreter
$ csvdiff
csvdiff: command not found

turion avatar Mar 06 '20 15:03 turion

Can you please provide the output of the pypi2nix command?

seppeljordan avatar Mar 06 '20 16:03 seppeljordan

$ pypi2nix -e csvdiff
INFO: pypi2nix v2.0.4 running ...
INFO: Downloading wheels and creating wheelhouse ...
INFO: Downloading runtime requirements
WARNING: You are using pip version 20.0.dev0; however, version 20.0.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
WARNING: You are using pip version 20.0.dev0; however, version 20.0.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
WARNING: You are using pip version 20.0.dev0; however, version 20.0.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
INFO: Build wheels of setup and runtime requirements
INFO: Extracting metadata from pypi.python.org ...
INFO: -- sources ---------------------------------------------------------------
INFO: --------------------------------------------------------------------------
INFO: Generating Nix expressions ...
INFO: |-> writing /home/turion/python/requirements_override.nix
INFO: 
INFO: Nix expressions generated successfully.
INFO: 
INFO: To start development run:
INFO:     nix-shell requirements.nix -A interpreter
INFO: 
INFO: More information you can find at
INFO:     https://github.com/nix-community/pypi2nix

Or did you mean the generated files?

turion avatar Mar 06 '20 16:03 turion

Note that there is a tiny chance that it's an upstream error and csvdiff is broken (in that it doesn't contain a proper executable). I haven't been able to rule that out yet.

turion avatar Mar 06 '20 16:03 turion

I now understand that the executable can be found in ./env/bin/. I expected it to be in the path. So if that's intended behaviour, we can close.

turion avatar Mar 06 '20 16:03 turion

Easiest thing I've found is to do PATH=$PATH:$(nix-build requirements.nix)/bin nix-shell requirements.txt

domenkozar avatar May 18 '20 09:05 domenkozar