Skip to content

Commit f3b3945

Browse files
author
Release Manager
committed
gh-36885: Switch more Python toolchain packages to use (platform-independent) wheels <!-- ^^^^^ Please provide a concise, informative and self-explanatory title. Don't put issue numbers in there, do this in the PR body below. For example, instead of "Fixes #1234" use "Introduce new method to calculate 1+1" --> <!-- Describe your changes here in detail --> We simplify the Sage distribution by installing more Python packages as platform-independent wheels. - No longer use direct installation using the deprecated `setup.py install` - `pip` bootstraps itself from its wheel - `setuptools` is installed as a wheel - remove the 2nd copy of setuptools (SPKG `setuptools_wheel`) We also add the build backends `hatchling` and `flit_core` to `PYTHON_TOOLCHAIN`. This fixes some missing dependencies, including `editables` (as reported in https://groups.google.com/g/sage- release/c/uP-rwlM__MU/m/oU-49z9VAwAJ). The package `deprecation` is no longer used by any package (has it been ... deprecated?) and is removed here. <!-- Why is this change required? What problem does it solve? --> <!-- If this PR resolves an open issue, please link to it here. For example "Fixes #12345". --> <!-- If your change requires a documentation PR, please link it appropriately. --> ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> <!-- If your change requires a documentation PR, please link it appropriately --> <!-- If you're unsure about any of these, don't hesitate to ask. We're here to help! --> <!-- Feel free to remove irrelevant items. --> - [x] The title is concise, informative, and self-explanatory. - [x] 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 accordingly. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on - #12345: short description why this is a dependency - #34567: ... --> - Depends on #36888 (for fixing the html workflow) <!-- If you're unsure about any of these, don't hesitate to ask. We're here to help! --> URL: #36885 Reported by: Matthias Köppe Reviewer(s): Dima Pasechnik
2 parents 0fb7727 + 86105b4 commit f3b3945

File tree

94 files changed

+127
-246
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

94 files changed

+127
-246
lines changed

build/bin/sage-dist-helpers

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ sdh_pip_install() {
244244
# Our default after #33789 (Sage 9.7): We allow the package to provision
245245
# its build environment using the stored wheels.
246246
# We pass --find-links.
247-
# The SPKG needs to declare "setuptools_wheel" as a dependency.
247+
# The SPKG needs to declare "setuptools" as a dependency.
248248
build_isolation_option="--find-links=$SAGE_SPKG_WHEELS"
249249
;;
250250
--no-build-isolation)

build/bin/sage-spkg

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,9 @@ else
509509
# just copy to dist/ and create a simple install script.
510510
mkdir -p dist
511511
cp "$PKG_SRC" dist/
512-
echo "sdh_store_and_pip_install_wheel ." > spkg-install.in
512+
if [ ! -f spkg-install.in ]; then
513+
echo "sdh_store_and_pip_install_wheel ." > spkg-install.in
514+
fi
513515
;;
514516
*)
515517
# Source tarball

build/make/Makefile.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ all-toolchain: base-toolchain
324324

325325
# Shorthand for a list of packages sufficient for building and installing
326326
# typical Python packages from source. Wheel packages only need pip.
327-
PYTHON_TOOLCHAIN = setuptools pip setuptools_scm wheel setuptools_wheel
327+
PYTHON_TOOLCHAIN = setuptools pip setuptools_scm wheel flit_core hatchling
328328

329329
# Trac #32056: Avoid installed setuptools leaking into the build of python3 by uninstalling it.
330330
# It will have to be reinstalled anyway because of its dependency on $(PYTHON).

build/pkgs/calver/dependencies

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
| $(PYTHON_TOOLCHAIN) $(PYTHON)
1+
| pip $(PYTHON)
22

33
----------
44
All lines of this file are ignored except the first.

build/pkgs/deprecation/SPKG.rst

Lines changed: 0 additions & 18 deletions
This file was deleted.

build/pkgs/deprecation/checksums.ini

Lines changed: 0 additions & 5 deletions
This file was deleted.

build/pkgs/deprecation/dependencies

Lines changed: 0 additions & 4 deletions
This file was deleted.

build/pkgs/deprecation/distros/conda.txt

Lines changed: 0 additions & 1 deletion
This file was deleted.

build/pkgs/deprecation/install-requires.txt

Lines changed: 0 additions & 1 deletion
This file was deleted.

build/pkgs/deprecation/package-version.txt

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)