nixpkgs/pkgs/development/interpreters/python
Yarny0 e5d7325166 pythonCatchConflictsHook: avoid infinite recursion
Albeit counter-intutive, the `propagatedBuildInputs`
mechanism and the corresponding package files in
`nix-support/propagated-build-inputs`
can form a dependency cycle.
This can happen if a package adds itself to this file,
or if multiple outputs of one derivation reference each other.

An example for this is the `patchPpdFilesHook`:
In its mission to collect dependency packages with binaries
that might be required by the dependent package to be created,
it sometimes picks up the dependent package itself.
This indicates that if a file of the dependent package
is used, the package itself should also be installed.
In the case of a multiple output package,
it is also possible that two outputs depend on each other,
creating a dependency cycle.

Since commit 2651ddc7b0,
the `find_packages` function in `catch_conflicts.py`
recursively collects all `propagated-build-inputs` files.
If it encounters a dependency cycle, it must not follow the
cycle to avoid infinite recursion (and a stack overflow).

The commit at hand adds a check so that the function skips over
a package that it already encountered and processed earlier.
This does not loosen the script's checks as the script
still recursively collects all propagated build inputs.
2024-02-25 11:54:07 +01:00
..
catch_conflicts pythonCatchConflictsHook: avoid infinite recursion 2024-02-25 11:54:07 +01:00
conda
cpython cpython: allow full variant on all platformns where bluez is available 2024-02-17 14:05:32 +01:00
hooks Merge staging-next into staging 2024-02-18 06:01:34 +00:00
manylinux Merge pull request #196802 from jneem/manylinux 2023-07-02 23:23:55 +02:00
pypy pypy: add option to change optimization level, update homepage, cleanup 2023-12-10 03:10:47 +01:00
python2 Revert "python2/mk-python-derivation: disable catchConflictsHook" 2023-11-18 12:58:15 +01:00
rustpython rustpython: mark broken on x86_64-darwin 2023-11-22 19:20:39 +01:00
tests python.tests.tkinter: init 2023-08-19 14:00:56 +03:00
update-python-libraries update-python-libraries: support applications outside python-modules 2024-01-10 15:01:54 +01:00
default.nix python312: 3.12.1 -> 3.12.2 2024-02-08 00:54:57 +01:00
mk-python-derivation.nix mk-python-derivation: Add build-system argument 2024-02-18 17:40:42 +13:00
passthrufun.nix python: deprecate pythonForBuild in favor of pythonOnBuildForHost 2023-11-07 02:28:58 +02:00
python-packages-base.nix python311Packages.recursive-pth-loader: rename from recursivePthLoader 2024-01-25 22:13:17 +01:00
run_setup.py
setup-hook.nix
setup-hook.sh
sitecustomize.py
tests.nix pythonInterpreters.pypy39_prebuilt: fix tests eval (#278950) 2024-01-09 18:46:49 +01:00
with-packages.nix
wrap-python.nix treewide: change pythonForBuild to pythonOnBuildForHost 2023-11-05 17:42:12 -08:00
wrap.sh
wrapper.nix treewide: use optionalString instead of 'then ""' 2023-06-24 20:19:19 +02:00