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 python: Move catch_conflicts.py into subdirectory (#23600) 2017-04-01 12:22:36 +02:00
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 pythonPackages.fetchPypi: support SRI hashes 2019-07-11 18:01:04 +02:00
mk-python-derivation.nix Split buildPythonPackage into setup hooks 2019-09-06 15:18:45 +02:00
run_setup.py
setup-hook.nix Python: set DETERMINISTIC_BUILD and PYTHONHASHSEED in setupHook 2017-05-19 16:28:11 +02:00
setup-hook.sh python: make it possible to disable the python setup-hook 2019-04-28 09:20:41 +02:00
sitecustomize.py Python: introduce NIX_PYTHONEXECUTABLE in order to set sys.executable 2019-07-27 11:52:49 +02:00
with-packages.nix
wrap-python.nix Python: improve cross-compilation 2019-01-04 10:45:22 +01:00
wrap.sh python.pkgs.wrapPython: get rid of warning 2019-12-30 16:46:55 +01:00
wrapper.nix Python: introduce NIX_PYTHONEXECUTABLE in order to set sys.executable 2019-07-27 11:52:49 +02:00