Conversation
ae0a543 to
42a6ba4
Compare
There was a problem hiding this comment.
| find "$out/lib" -type f -name '*-nspkg.pth' -delete | |
| rm $SETUPTOOLS_NSPKG_PTH_FILES |
There was a problem hiding this comment.
Calling find twice is less efficient, but I did it on purpose just in case the hook finds more than one -nspkg.pth file. The second find call handles deletion properly even if there are spaces in the file name. I can also limit the code to only deleting the first file found, or leave a better comment. What do you think?
There was a problem hiding this comment.
Can't we tell find to exit with an error if it can't find files and then delete them right away?
There was a problem hiding this comment.
I don't know how to get find to work that way from reading the man page and testing a few things locally.
pkgs/development/interpreters/python/hooks/setuptools-legacy-namespace-hook.sh
Outdated
Show resolved
Hide resolved
|
I also tried updating sphinx to 7.1.0, which was released yesterday, but hesitant due to sphinx-doc/sphinx#11514. |
|
This will also take care of changing the names of |
cceedbd to
3f1211a
Compare
https://www.sphinx-doc.org/en/master/changes.html#release-7-0-1-released-may-12-2023 Co-authored-by: Theodore Ni <3806110+tjni@users.noreply.github.com>
These files are generated as part of a legacy flow for namespace packages, and they can cause issues when used alongside packages using a modern flow that doesn't create these files.
| disabledTests = lib.optionals isPyPy [ | ||
| # PyPy has not __builtins__ which get asserted | ||
| # https://doc.pypy.org/en/latest/cpython_differences.html#miscellaneous | ||
| "test_autosummary_generate_content_for_module" |
There was a problem hiding this comment.
|
@ofborg build python3.pkgs.wrapt |
|
closing in favor of #259350 |
Description of changes
This change also touches all of the
sphinxcontrib-*packages.We need to do a pass over all of them because, due to pypa/setuptools#3991, any of these packages that use the legacy setuptools namespace package code path need to remove the generated nspkg.pth file so that they play nice with the others that have migrated off of that code path. This logic is currently encapsulated in a setup hook.
As always, I am open to other approaches that solve this problem.
Things done
sandbox = trueset innix.conf? (See Nix manual)nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/)