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

build/pkgs/setuptools_scm: Upgrade to 8.1.0, fix dependency typing_extensions, change some packages to wheel #38226

Merged
merged 13 commits into from
Jul 12, 2024

Conversation

mkoeppe
Copy link
Contributor

@mkoeppe mkoeppe commented Jun 15, 2024

Currently several packages show a (non-fatal) build error like this:

[asttokens-2.4.1] [spkg-install] < INFO: pip is looking at multiple versions of setuptools-scm to determine
[asttokens-2.4.1] [spkg-install]   which version is compatible with other requirements. This could take a
[asttokens-2.4.1] [spkg-install]   while.
[asttokens-2.4.1] [spkg-install] < ERROR: Could not find a version that satisfies the requirement typing-
[asttokens-2.4.1] [spkg-install]   extensions (from setuptools-scm) (from versions: none)
[asttokens-2.4.1] [spkg-install] < ERROR: No matching distribution found for typing-extensions

The reason: setuptools_scm 8.0.4 (our current version) has an unconditional dependency on typing_extensions, but our spkg-configure.m4 marks that as "not required" when using Python >= 3.11.

In this PR:

  • We reduce several of these packages to (platform-independent) wheel packages (and incidental updates) -- so that there is no build dependency any more
  • Two packages (hatch_*) that were build dependencies only are deleted
  • We upgrade setuptools_scm to 8.1.0, which conditionalizes the dependency on typing_extensions on python_version < "3.10" https://github.com/pypa/setuptools_scm/blob/v8.1.0/pyproject.toml#L46

📝 Checklist

  • The title is concise and informative.
  • The description explains in detail what this PR is about.
  • I have linked a relevant issue or discussion.
  • I have created tests covering the changes.
  • I have updated the documentation and checked the documentation preview.

⌛ Dependencies

Copy link

github-actions bot commented Jun 15, 2024

Documentation preview for this PR (built with commit a8d254d; changes) is ready! 🎉
This preview will update shortly after each push to this PR.

@kwankyu
Copy link
Collaborator

kwankyu commented Jul 7, 2024

Incremental build with this PR fails:

...
[setuptools_scm-8.1.0] Finished installing setuptools_scm-8.1.0
[setuptools_scm-8.1.0] real 1m3.949s user 0m7.071s sys 0m1.921s
...
[sage_conf-10.4.rc2] [spkg-install]   File "<frozen importlib._bootstrap>", line 1324, in _find_and_load_unlocked
[sage_conf-10.4.rc2] [spkg-install] ModuleNotFoundError: No module named 'setuptools'
[sage_conf-10.4.rc2] [spkg-install] 

but second attempt starting at where it stopped is continuing fine.

@kwankyu
Copy link
Collaborator

kwankyu commented Jul 7, 2024

From the incremental build, I got these failures

sage -t --warn-long 66.3 --random-seed=241645342276889418979075661247205680427 src/sage/misc/sageinspect.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=241645342276889418979075661247205680427 src/sage/interfaces/r.py  # 187 doctests failed
sage -t --warn-long 66.3 --random-seed=241645342276889418979075661247205680427 src/sage/repl/ipython_tests.py  # 2 doctests failed
sage -t --warn-long 66.3 --random-seed=241645342276889418979075661247205680427 src/sage/interfaces/interface.py  # 10 doctests failed
sage -t --warn-long 66.3 --random-seed=241645342276889418979075661247205680427 src/doc/en/prep/Quickstarts/Statistics-and-Distributions.rst  # 6 doctests failed
sage -t --warn-long 66.3 --random-seed=241645342276889418979075661247205680427 src/sage/stats/r.py  # 1 doctest failed

After build from scratch, I got

sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/misc/sagedoc.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/doc/en/thematic_tutorials/sandpile.rst  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/misc/cachefunc.pyx  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/misc/sageinspect.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/misc/cython.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/sandpiles/sandpile.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/repl/ipython_tests.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/graphs/graph_decompositions/fast_digraph.pyx  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/env.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/parallel/decorate.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/sets/set_from_iterator.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/doc/en/developer/coding_basics.rst  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/misc/sphinxify.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/repl/interface_magic.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/structure/dynamic_class.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/structure/mutability.pyx  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/misc/bindable_class.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage/databases/findstat.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage_docbuild/builders.py  # 1 doctest failed
sage -t --warn-long 66.3 --random-seed=86543571997746411802597110925399306755 src/sage_docbuild/__main__.py  # 1 doctest failed

@kwankyu
Copy link
Collaborator

kwankyu commented Jul 8, 2024

None of the failures is definitely new in this PR.

Copy link
Collaborator

@kwankyu kwankyu left a comment

Choose a reason for hiding this comment

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

Works well.

@mkoeppe
Copy link
Contributor Author

mkoeppe commented Jul 8, 2024

Thanks!

@kwankyu kwankyu mentioned this pull request Jul 8, 2024
93 tasks
@vbraun vbraun merged commit a13ffad into sagemath:develop Jul 12, 2024
33 of 44 checks passed
@mkoeppe mkoeppe deleted the setuptools_scm_8_1 branch July 13, 2024 04:26
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.

3 participants