3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/interpreters/python
Jan Tojnar f4e74edd8c python.pkgs.wrapPython: get rid of warning
When `makeWrapperArgs` variable is not set, `declare -p makeWrapperArgs`
will return with 1 and print an error message to stderr.

I did not handle the non-existence case in b0633406cb
because I thought `mk-python-derivation` will always define `makeWrapperArgs`
but `wrapProgram` can be called independently. And even with `mk-python-derivation`,
`makeWrappers` will not be set unless explicitly declared in the derivation
because of https://github.com/NixOS/nix/issues/1461.

I was lead to believe that because the builds were succeeding and I confirmed
that the mechanism fails when the variable is not defined and `-o nounset` is enabled.
It appears that `wrapPython` setup hook is not running under `-o nounset`, though,
invaldating the assumption.

Now we are checking that the variable exists before checking its type, which
will get rid of the warning and also prevent future error when `-o nounset`
is enabled in the setup hook.

For more information, see the discussion at
https://github.com/NixOS/nixpkgs/commit/a6bb2ede232940a96150da7207a3ecd15eb6328
2019-12-30 16:46:55 +01:00
..
catch_conflicts
cpython python: remove _manylinux.py 2019-12-16 16:37:16 +01:00
graalpython pythonInterpreters.graalpython37: init 2019-10-22 09:16:18 +02:00
hooks pythonPackages.pipBuildHook: fix unbound variable 2019-11-20 05:06:51 +01:00
manylinux Fix manylinux packages 2019-12-13 11:40:44 +01:00
pypy python: remove _manylinux.py 2019-12-16 16:37:16 +01:00
update-python-libraries update-python-libraries: ignore pyproject 2019-11-22 08:37:03 +01:00
default.nix Merge branch 'staging-next' into staging 2019-12-25 05:18:52 +01:00
fetchpypi.nix
mk-python-derivation.nix
run_setup.py
setup-hook.nix
setup-hook.sh
sitecustomize.py
with-packages.nix
wrap-python.nix
wrap.sh python.pkgs.wrapPython: get rid of warning 2019-12-30 16:46:55 +01:00
wrapper.nix