Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sphinx: 5.3.0 -> 7.0.1 #244625

Closed
wants to merge 31 commits into from
Closed

sphinx: 5.3.0 -> 7.0.1 #244625

wants to merge 31 commits into from

Conversation

tjni
Copy link
Contributor

@tjni tjni commented Jul 21, 2023

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
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 23.11 Release Notes (or backporting 23.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

#
SETUPTOOLS_NSPKG_PTH_FILES="$(find "$out/lib" -type f -name '*-nspkg.pth')"
if [[ -n "$SETUPTOOLS_NSPKG_PTH_FILES" ]]; then
find "$out/lib" -type f -name '*-nspkg.pth' -delete
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
find "$out/lib" -type f -name '*-nspkg.pth' -delete
rm $SETUPTOOLS_NSPKG_PTH_FILES

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't we tell find to exit with an error if it can't find files and then delete them right away?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know how to get find to work that way from reading the man page and testing a few things locally.

@tjni
Copy link
Contributor Author

tjni commented Jul 25, 2023

I also tried updating sphinx to 7.1.0, which was released yesterday, but hesitant due to sphinx-doc/sphinx#11514.

@tjni
Copy link
Contributor Author

tjni commented Jul 25, 2023

This will also take care of changing the names of sphinxcontrib_httpdomain and sphinxcontrib_newsfeed packages per #245383.

@tjni tjni changed the base branch from python-updates to staging August 3, 2023 08:32
@tjni tjni marked this pull request as ready for review August 3, 2023 08:32
"test_follows_redirects_on_GET"
"test_connect_to_selfsigned_fails"
] ++ lib.optionals isPyPy [
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"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mweinelt
Copy link
Member

@ofborg build python3.pkgs.wrapt

@natsukium natsukium mentioned this pull request Oct 6, 2023
12 tasks
@natsukium
Copy link
Member

closing in favor of #259350

@natsukium natsukium closed this Oct 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants