nixpkgs/pkgs/development/interpreters/python
Frederik Rietdijk d68aba4cfb Python: script names now include full path
Certain programs, like zim, calibre and now also apparently mercurial,
rely on sys.argv[0] providing not just the script name but the full
path.

The Python docs [1] state the following on the matter:

> argv[0] is the script name (it is operating system dependent whether
this is a full pathname or not).

Therefore, scripts should not expect to receive a full path.
Unfortunately some do. While this can be considered a bug, there doesn't
seem any reason not to provide the full path. Therefore we now provide
the full path.

[1]
https://docs.python.org/3.5/library/sys.html?highlight=sys.argv#sys.argv
2017-01-02 11:29:11 +01:00
..
cpython python36: 3.6.0rc1 -> 3.6.0 2016-12-24 16:00:52 +01:00
pypy/2.7 Python interpreters: add pkgs attribute 2016-12-05 09:43:44 +01:00
build-python-package-common.nix buildPythonPackage: install builds reproducibly 2016-12-13 14:45:05 +01:00
build-python-package-flit.nix buildPythonPackage: refactor 2016-12-05 10:29:22 +01:00
build-python-package-setuptools.nix buildPythonPackage: refactor 2016-12-05 10:29:22 +01:00
build-python-package-wheel.nix buildPythonPackage: refactor 2016-12-05 10:29:22 +01:00
build-python-package.nix buildPythonPackage: refactor 2016-12-05 10:29:22 +01:00
catch_conflicts.py Python: move python-modules/generic to interpreter folder 2016-09-01 16:16:31 +02:00
mk-python-derivation.nix buildPythonPackage: refactor 2016-12-05 10:29:22 +01:00
run_setup.py Python: move python-modules/generic to interpreter folder 2016-09-01 16:16:31 +02:00
with-packages.nix python: add python.withPackages function 2016-05-29 15:12:23 +02:00
wrap-python.nix Python: script names now include full path 2017-01-02 11:29:11 +01:00
wrap.sh Python: move python-modules/generic to interpreter folder 2016-09-01 16:16:31 +02:00
wrapper.nix python.buildenv: don't filter non-python packages 2016-09-17 14:28:12 +02:00