Skip to content

Commit 67e7f95

Browse files
committed
Merge branch 'develop' into remove-spurious-doc-diffs
2 parents c81d50f + 07a2afd commit 67e7f95

File tree

266 files changed

+1939
-1477
lines changed

Some content is hidden

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

266 files changed

+1939
-1477
lines changed

.github/workflows/build.yml

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,20 +85,19 @@ jobs:
8585
(cd worktree-image && git commit -q -m "current changes" --allow-empty -a && git am; git reset --quiet old; git add -N .) < upstream/ci_fixes.patch
8686
fi
8787
88-
- name: Incremental build, test changed files (sage -t --new)
88+
- name: Incremental build
8989
id: incremental
9090
run: |
9191
# Now re-bootstrap and build. The build is incremental because we were careful with the timestamps.
92-
# We run tests with "sage -t --new"; this only tests the uncommitted changes.
93-
./bootstrap && make build && ./sage -t --new -p2
92+
./bootstrap && make build
9493
working-directory: ./worktree-image
9594
env:
9695
MAKE: make -j2 --output-sync=recurse
9796
SAGE_NUM_THREADS: 2
9897

99-
- name: Build and test modularized distributions
98+
- name: Build modularized distributions
10099
if: always() && steps.worktree.outcome == 'success'
101-
run: make V=0 tox && make pypi-wheels
100+
run: make V=0 tox && make SAGE_CHECK=no pypi-wheels
102101
working-directory: ./worktree-image
103102
env:
104103
MAKE: make -j2 --output-sync=recurse
@@ -143,6 +142,26 @@ jobs:
143142
MAKE: make -j2 --output-sync=recurse
144143
SAGE_NUM_THREADS: 2
145144

145+
# Testing
146+
147+
- name: Test changed files (sage -t --new)
148+
if: always() && steps.build.outcome == 'success'
149+
run: |
150+
# We run tests with "sage -t --new"; this only tests the uncommitted changes.
151+
./sage -t --new -p2
152+
working-directory: ./worktree-image
153+
env:
154+
MAKE: make -j2 --output-sync=recurse
155+
SAGE_NUM_THREADS: 2
156+
157+
- name: Test modularized distributions
158+
if: always() && steps.build.outcome == 'success'
159+
run: make V=0 tox && make pypi-wheels-check
160+
working-directory: ./worktree-image
161+
env:
162+
MAKE: make -j2 --output-sync=recurse
163+
SAGE_NUM_THREADS: 2
164+
146165
- name: Pytest
147166
if: contains(github.ref, 'pytest')
148167
run: |

.github/workflows/ci-conda.yml

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,6 @@ jobs:
3939
env:
4040
GH_TOKEN: ${{ github.token }}
4141

42-
- name: Check for Miniconda
43-
id: check_conda
44-
run: echo ::set-output name=installed::$CONDA
45-
46-
# Miniconda is installed by default in the ubuntu-latest, however not in the act-image to run it locally
47-
- name: Install Miniconda
48-
if: steps.check_conda.outputs.installed == ''
49-
run: |
50-
wget https://repo.anaconda.com/miniconda/Miniconda3-py39_4.10.3-Linux-x86_64.sh -O ~/miniconda.sh
51-
bash ~/miniconda.sh -b -p $HOME/miniconda
52-
echo "CONDA=$HOME/miniconda" >> $GITHUB_ENV
53-
5442
- name: Create conda environment files
5543
run: ./bootstrap-conda
5644

@@ -61,12 +49,13 @@ jobs:
6149
key:
6250
${{ runner.os }}-conda-${{ hashFiles('src/environment-3.11.yml') }}
6351

64-
- name: Setup Conda
52+
- name: Setup Conda environment
6553
uses: conda-incubator/setup-miniconda@v2
6654
with:
6755
python-version: ${{ matrix.python }}
68-
mamba-version: "*"
69-
channels: conda-forge,defaults
56+
miniforge-version: latest
57+
use-mamba: true
58+
channels: conda-forge
7059
channel-priority: true
7160
activate-environment: sage
7261
environment-file: src/${{ matrix.conda-env }}-${{ matrix.python }}.yml
@@ -92,7 +81,7 @@ jobs:
9281
run: |
9382
# Use --no-deps and pip check below to verify that all necessary dependencies are installed via conda.
9483
pip install --no-build-isolation --no-deps -v -v -e ./pkgs/sage-conf ./pkgs/sage-setup
95-
pip install --no-build-isolation --no-deps -v -v -e ./src
84+
pip install --no-build-isolation --no-deps --config-settings editable_mode=compat -v -v -e ./src
9685
env:
9786
SAGE_NUM_THREADS: 2
9887

.github/workflows/ci-linux.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,46 @@ permissions:
3434

3535
jobs:
3636

37+
# standard-pre for the default platform (used by build.yml etc.)
38+
default-pre:
39+
uses: ./.github/workflows/docker.yml
40+
with:
41+
# Build from scratch
42+
docker_targets: "with-system-packages configured with-targets-pre"
43+
# FIXME: duplicated from env.TARGETS
44+
targets_pre: all-sage-local
45+
tox_system_factors: >-
46+
["ubuntu-focal"]
47+
tox_packages_factors: >-
48+
["standard"]
49+
docker_push_repository: ghcr.io/${{ github.repository }}/
50+
51+
# standard for the default platform (used by build.yml etc.)
52+
default:
53+
if: ${{ success() || failure() }}
54+
needs: [default-pre]
55+
uses: ./.github/workflows/docker.yml
56+
with:
57+
# Build incrementally from previous stage (pre)
58+
incremental: true
59+
free_disk_space: true
60+
from_docker_repository: ghcr.io/${{ github.repository }}/
61+
from_docker_target: "with-targets-pre"
62+
docker_targets: "with-targets with-targets-optional"
63+
# FIXME: duplicated from env.TARGETS
64+
targets: build doc-html
65+
targets_optional: ptest
66+
tox_system_factors: >-
67+
["ubuntu-focal"]
68+
tox_packages_factors: >-
69+
["standard"]
70+
docker_push_repository: ghcr.io/${{ github.repository }}/
71+
72+
# All platforms. This duplicates the default platform, but why not,
73+
# it makes it more robust regarding random timeouts.
74+
3775
standard-pre:
76+
if: ${{ success() || failure() }}
3877
uses: ./.github/workflows/docker.yml
3978
with:
4079
# Build from scratch

.github/workflows/dist.yml

Lines changed: 33 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,8 @@ jobs:
1818

1919
release_dist:
2020

21-
# This job, in contrast to "dist" in ci-macos.yml,
22-
# does not use "configure --enable-download-from-upstream-url"
23-
# (the default since #32390).
21+
# This job first checks whether "configure --enable-download-from-upstream-url"
22+
# (the default since #32390) is needed.
2423
#
2524
# In this way, we check that all necessary package tarballs
2625
# have already been uploaded to the Sage server at the time
@@ -37,13 +36,42 @@ jobs:
3736
run: |
3837
sudo DEBIAN_FRONTEND=noninteractive apt-get update
3938
sudo DEBIAN_FRONTEND=noninteractive apt-get install $(build/bin/sage-get-system-packages debian _bootstrap)
40-
- name: make dist
39+
- name: make dist (--disable-download-from-upstream-url)
4140
run: |
4241
./bootstrap -D && ./configure --disable-download-from-upstream-url && make dist
42+
env:
43+
MAKE: make -j8
44+
- name: make dist (--enable-download-from-upstream-url)
45+
if: failure()
46+
run: |
47+
./configure && make dist
48+
env:
49+
MAKE: make -j8
4350
- uses: actions/upload-artifact@v3
51+
if: success() || failure()
52+
with:
53+
path: |
54+
dist/*.tar.gz
55+
upstream
56+
name: release_dist
57+
58+
release:
59+
60+
needs: release_dist
61+
runs-on: ubuntu-latest
62+
if: (success() || failure()) && github.repository == 'sagemath/sage' && startsWith(github.ref, 'refs/tags/') && !contains(github.ref, 'beta') && !contains(github.ref, 'rc')
63+
steps:
64+
- uses: actions/download-artifact@v3
4465
with:
45-
path: "dist/*.tar.gz"
4666
name: release_dist
67+
- uses: softprops/action-gh-release@v1
68+
with:
69+
generate_release_notes: true
70+
files: |
71+
dist/*
72+
upstream/*
73+
permissions:
74+
contents: write
4775

4876
sdists_for_pypi:
4977

.github/workflows/docker.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ on:
5151
"almalinux-9-python3.11",
5252
"gentoo-python3.10",
5353
"gentoo-python3.11",
54+
"gentoo-python3.12",
5455
"archlinux-latest",
5556
"opensuse-15.3-gcc_11-python3.9",
5657
"opensuse-15.4-gcc_11-python3.10",

.github/workflows/lint.yml

Lines changed: 13 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -14,60 +14,32 @@ concurrency:
1414
cancel-in-progress: true
1515

1616
jobs:
17-
lint-pycodestyle:
18-
name: Code style check with pycodestyle
17+
lint:
18+
name: Lint
1919
runs-on: ubuntu-latest
2020
steps:
2121
- name: Checkout
2222
uses: actions/checkout@v4
23+
2324
- name: Merge CI fixes from sagemath/sage
2425
run: |
2526
.ci/merge-fixes.sh
2627
env:
2728
GH_TOKEN: ${{ github.token }}
29+
2830
- name: Set up Python
2931
uses: actions/setup-python@v4
3032
with:
3133
python-version: 3.9
32-
- name: Install pycodestyle
33-
run: pip install tox pycodestyle
34-
- name: Lint using pycodestyle
34+
35+
- name: Install dependencies
36+
run: pip install tox pycodestyle relint
37+
38+
- name: Code style check with pycodestyle
3539
run: tox -e pycodestyle-minimal
36-
lint-relint:
37-
name: Code style check with relint
38-
runs-on: ubuntu-latest
39-
steps:
40-
- name: Checkout
41-
uses: actions/checkout@v4
42-
- name: Merge CI fixes from sagemath/sage
43-
run: |
44-
.ci/merge-fixes.sh
45-
env:
46-
GH_TOKEN: ${{ github.token }}
47-
- name: Set up Python
48-
uses: actions/setup-python@v4
49-
with:
50-
python-version: 3.9
51-
- name: Install relint
52-
run: pip install tox relint
53-
- name: Lint using relint
40+
41+
- name: Code style check with relint
5442
run: tox -e relint -- src/sage/
55-
lint-rst:
56-
name: Validate docstring markup as RST
57-
runs-on: ubuntu-latest
58-
steps:
59-
- name: Checkout
60-
uses: actions/checkout@v4
61-
- name: Merge CI fixes from sagemath/sage
62-
run: |
63-
.ci/merge-fixes.sh
64-
env:
65-
GH_TOKEN: ${{ github.token }}
66-
- name: Set up Python
67-
uses: actions/setup-python@v4
68-
with:
69-
python-version: 3.9
70-
- name: Install tox
71-
run: pip install tox
72-
- name: Lint using tox -e rst
43+
44+
- name: Validate docstring markup as RST
7345
run: tox -e rst

.github/workflows/push_to_docker_hub.yml

Lines changed: 9 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ on:
55
# Allow to run manually
66
branches:
77
- 'develop'
8-
- 'docker_hub_gha'
98
push:
109
tags:
1110
# Just create image on pushing a tag
@@ -14,6 +13,7 @@ on:
1413
jobs:
1514
sagemath-dev:
1615
name: Build Docker image on target make-build and push to DockerHub sagemath-dev
16+
# target make-build replaces former sagemath-dev, see https://github.com/sagemath/sage/pull/36047
1717
runs-on: ubuntu-latest
1818
steps:
1919
- name: Checkout
@@ -25,10 +25,9 @@ jobs:
2525
id: set_tag
2626
run: |
2727
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
28-
TAG_NAME=$(git tag --sort=v:refname | tail -1)
28+
TAG_NAME=$(git tag --sort=creatordate | tail -1)
2929
TAG="sagemath/sagemath-dev:$TAG_NAME"
3030
TAG_LIST="$TAG, sagemath/sagemath-dev:develop"
31-
TAG_LIST="$TAG" # don't tag develop until meaning of sagemath-dev is clear
3231
echo "TAG_NAME=$TAG_NAME" >> $GITHUB_ENV
3332
echo "TAG=$TAG" >> $GITHUB_ENV
3433
echo "TAG_LIST=$TAG_LIST" >> $GITHUB_ENV
@@ -37,30 +36,20 @@ jobs:
3736
id: upd_tag_list
3837
run: |
3938
TAG_LIST="${{ env.TAG_LIST }}, sagemath/sagemath-dev:latest"
40-
TAG_LIST="${{ env.TAG_LIST }}" # don't tag latest until meaning of sagemath-dev is clear
4139
echo "TAG_LIST=$TAG_LIST" >> $GITHUB_ENV
4240
if: "!contains(env.TAG_NAME, 'beta') && !contains(env.TAG_NAME, 'rc')"
4341

44-
- name: Check env
45-
run: |
46-
echo ${{ env.TAG_NAME }}
47-
echo ${{ env.TAG }}
48-
echo ${{ env.TAG_LIST }}
49-
50-
- name: Set up QEMU
51-
uses: docker/setup-qemu-action@v2
52-
5342
- name: Set up Docker Buildx
54-
uses: docker/setup-buildx-action@v2
43+
uses: docker/setup-buildx-action@v3
5544

5645
- name: Login to Docker Hub
57-
uses: docker/login-action@v2
46+
uses: docker/login-action@v3
5847
with:
5948
username: ${{ secrets.DOCKERHUB_USERNAME }}
6049
password: ${{ secrets.DOCKERHUB_TOKEN }}
6150

6251
- name: Build and push make-build
63-
uses: docker/build-push-action@v4
52+
uses: docker/build-push-action@v5
6453
with:
6554
context: .
6655
file: docker/Dockerfile
@@ -84,7 +73,7 @@ jobs:
8473
id: set_tag
8574
run: |
8675
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
87-
TAG_NAME=$(git tag --sort=v:refname | tail -1)
76+
TAG_NAME=$(git tag --sort=creatordate | tail -1)
8877
TAG="sagemath/sagemath:$TAG_NAME"
8978
TAG_LIST="$TAG, sagemath/sagemath:develop"
9079
BASE="sagemath/sagemath-dev:$TAG_NAME"
@@ -100,20 +89,17 @@ jobs:
10089
echo "TAG_LIST=$TAG_LIST" >> $GITHUB_ENV
10190
if: "!contains(env.TAG_NAME, 'beta') && !contains(env.TAG_NAME, 'rc')"
10291

103-
- name: Set up QEMU
104-
uses: docker/setup-qemu-action@v2
105-
10692
- name: Set up Docker Buildx
107-
uses: docker/setup-buildx-action@v2
93+
uses: docker/setup-buildx-action@v3
10894

10995
- name: Login to Docker Hub
110-
uses: docker/login-action@v2
96+
uses: docker/login-action@v3
11197
with:
11298
username: ${{ secrets.DOCKERHUB_USERNAME }}
11399
password: ${{ secrets.DOCKERHUB_TOKEN }}
114100

115101
- name: Build and push sagemath
116-
uses: docker/build-push-action@v4
102+
uses: docker/build-push-action@v5
117103
with:
118104
context: .
119105
file: docker/Dockerfile

.upstream.d/10-SAGE_SERVER

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# When SAGE_SERVER is set, it should be an https/https server in the format of Sage mirrors.
2+
${SAGE_SERVER}/spkg/upstream/${SPKG}/
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Upstream packages as uploaded as GitHub release assets.
2+
# This file is automatically updated by the sage-update-version script.
3+
https://github.com/sagemath/sage/releases/download/10.2/
4+
https://github.com/sagemath/sage/releases/download/10.1/
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
https://www.sagemath.org/mirror_list

0 commit comments

Comments
 (0)