From e0787d3c7986cabb175c278cf774fb8b7f4c8f91 Mon Sep 17 00:00:00 2001 From: Taewoon Kim Date: Mon, 30 Nov 2026 11:08:28 +0900 Subject: [PATCH] Release day: a final release merges the dev-engine bump and the new notices before the tag The native build of a final tag links the engine of the tag and compares THIRD_PARTY_NOTICES.md with it; only a SNAPSHOT engine skips the check. With the bump after the tag, 26.12.1 would stop at Build the wheel on every platform. 26.11.1 already had its bump (#258) inside the tag. --- .github/ISSUE_TEMPLATE/release.md | 52 +++++++++---------- .../ROOT/pages/development/release.adoc | 44 ++++++++-------- 2 files changed, 49 insertions(+), 47 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/release.md b/.github/ISSUE_TEMPLATE/release.md index 7f1cfcb..1385096 100644 --- a/.github/ISSUE_TEMPLATE/release.md +++ b/.github/ISSUE_TEMPLATE/release.md @@ -9,7 +9,7 @@ Open this issue once per release, when upstream ArcadeDB has released an engine - ``: the tag to push, for example the engine release `A.B.C`. A Python-only fix of a released engine is `A.B.C.postN`. - ``: the previous release of the same package on PyPI (the JVM and the native package can differ), or `-` for the first release of a package. -- ``: the first dev version of the next base, `A.B.C.dev0` (see step 7). +- ``: the first dev version of the next base, `A.B.C.dev0` (see step 2). Every step says who does it: script (run the command, read the result), CI (a workflow does it, you wait), or owner (a decision that is not automated). The procedure and the reasons are on the docs page `development/release.adoc`, section "Release day". @@ -21,8 +21,27 @@ Every step says who does it: script (run the command, read the result), CI (a wo uv run --no-project python -I scripts/release_preflight.py ``` -- [ ] 2. owner: for a final or post release, the native readiness bar is met and the repository variable `ARCADEDB_NATIVE_READINESS_BAR_MET` is `true` (the preflight line `(g)` shows it, or SKIPs when the login cannot read variables). -- [ ] 3. owner: the go. Nothing is published before this box is ticked. Before it, preview the GitHub Release notes and check that every pull request of this release has the milestone `` (a pull request without it is not listed in a `devN` or final release; a `postN` lists the commit range instead and needs no milestone): +- [ ] 2. script, then CI (a final release only, before the tag; a `postN` release keeps its engine and skips steps 2 to 4): the dev-engine bump PR. The native build of a final tag compares `native/wheel/THIRD_PARTY_NOTICES.md` with the engine of the tag, so notices that name the previous engine stop it on every platform (#547). Start once the lines `(a)` to `(c)` of step 1 pass. Open it from a worktree on a branch off `origin/main`. Pick `` from the version of upstream `main`: the command prints the next base. If it prints ``, upstream has not moved on yet: wait, because a dev version of a released base is refused. + + ```bash + curl -fsS https://raw.githubusercontent.com/ArcadeData/arcadedb/main/pom.xml | sed -n '/arcadedb-parent<\/artifactId>/,/<\/version>/ s/.*\(.*\)-SNAPSHOT<\/version>.*/\1/p' + # is that base followed by .dev0 + uv run --no-project python scripts/bump_engine.py --engine --dev-version --check + uv run --no-project python scripts/bump_engine.py --engine --dev-version + ``` + +- [ ] 3. script: refresh the notices the new engine needs, in the same PR. First refresh the kept engine NOTICE (`git -C show :NOTICE > native/wheel/ARCADEDB_ENGINE_NOTICE`; the generated notices embed it). The first `Test native (arcadedb)` run on the bump PR stops at the notices drift check on purpose and uploads the generated file. Download it, commit it, push, and wait for the run to go green. + + ```bash + gh run list -R ArcadeData/arcadedb-python --workflow test-native.yml --branch --limit 1 + gh run download -R ArcadeData/arcadedb-python -n native-build-record-linux-x86_64 -D + cp /THIRD_PARTY_NOTICES.generated.md native/wheel/THIRD_PARTY_NOTICES.md + uv run --no-project python scripts/bump_engine.py --engine --dev-version --check + ``` + +- [ ] 4. CI, then owner: merge the bump PR when every check is green, and delete the branch and the worktree. Run step 1 again: its line `(e)` must read green runs of `main` on the new engine. The tests and skip-list lines that waited for the new engine go later, in a PR of their own: `git grep -n -i "native build links\|native image links"`. +- [ ] 5. owner: for a final or post release, the native readiness bar is met and the repository variable `ARCADEDB_NATIVE_READINESS_BAR_MET` is `true` (the preflight line `(g)` shows it, or SKIPs when the login cannot read variables). +- [ ] 6. owner: the go. Nothing is published before this box is ticked. Before it, preview the GitHub Release notes and check that every pull request of this release has the milestone `` (a pull request without it is not listed in a `devN` or final release; a `postN` lists the commit range instead and needs no milestone): ```bash uv run --no-project python -I scripts/release_notes.py --dry-run @@ -30,13 +49,13 @@ Every step says who does it: script (run the command, read the result), CI (a wo ## The tag (the only publishing step) -- [ ] 4. owner: push the tag. It is the bare version, with no `v`, on the tip of `main`. One tag starts `release-jvm.yml` and `release-native.yml`. +- [ ] 7. owner: push the tag. It is the bare version, with no `v`, on the tip of `main`. One tag starts `release-jvm.yml` and `release-native.yml`. ```bash git fetch origin main --no-tags && git tag origin/main && git push origin ``` -- [ ] 5. CI: both release workflows finish and publish, then `release-notes.yml` creates the GitHub Release and, for a final release, closes the milestone. Note the two run ids (the native build takes the longest). To retry a failed upload, re-run only the publish job, never the whole workflow. Both publish jobs wait for your approval (the environments `pypi-jvm` and `pypi` each have you as required reviewer): approve the JVM one when its tests are green. For the native package of a final or `postN` release (a `devN` release skips the smoke), the `pypi` deployment waits for your approval: before you approve it, run the speed smoke on the wheel of the artifact `native-release-dist` (docs page "Speed smoke of the native wheel", issue #404), once against each of its two baselines, and keep the library sha256 and both ratios. A wheel that fails the smoke is a slow build of the same commit: reject the deployment and re-run all jobs for a new build, up to four times. Keep the JSON of every attempt. The notes lines wait for step 10, because the GitHub Release does not exist before both packages are published. +- [ ] 8. CI: both release workflows finish and publish, then `release-notes.yml` creates the GitHub Release and, for a final release, closes the milestone. Note the two run ids (the native build takes the longest). To retry a failed upload, re-run only the publish job, never the whole workflow. Both publish jobs wait for your approval (the environments `pypi-jvm` and `pypi` each have you as required reviewer): approve the JVM one when its tests are green. For the native package of a final or `postN` release (a `devN` release skips the smoke), the `pypi` deployment waits for your approval: before you approve it, run the speed smoke on the wheel of the artifact `native-release-dist` (docs page "Speed smoke of the native wheel", issue #404), once against each of its two baselines, and keep the library sha256 and both ratios. A wheel that fails the smoke is a slow build of the same commit: reject the deployment and re-run all jobs for a new build, up to four times. Keep the JSON of every attempt. The notes lines wait for step 10, because the GitHub Release does not exist before both packages are published. ```bash gh run list -R ArcadeData/arcadedb-python --branch --limit 6 @@ -45,36 +64,17 @@ Every step says who does it: script (run the command, read the result), CI (a wo ## After the tag -- [ ] 6. script: verify both packages on PyPI. Run them under bash. The scripts read from GitHub and PyPI only, and download about 0.6 GB: point `WORK` at a disk, not a tmpfs. The exit code is the number of FAILs. +- [ ] 9. script: verify both packages on PyPI. Run them under bash. The scripts read from GitHub and PyPI only, and download about 0.6 GB: point `WORK` at a disk, not a tmpfs. The exit code is the number of FAILs. ```bash scripts/after_tag_verify.sh PACKAGE=native scripts/after_tag_verify.sh ``` - Native only: the wheel on PyPI must be the wheel that passed the speed smoke. Download the `manylinux_2_28_x86_64` wheel from PyPI as in "Get the files" of the speed smoke page and compare its library hash with the one of step 5. A different hash is a different build, and the smoke says nothing about it. + Native only: the wheel on PyPI must be the wheel that passed the speed smoke. Download the `manylinux_2_28_x86_64` wheel from PyPI as in "Get the files" of the speed smoke page and compare its library hash with the one of step 8. A different hash is a different build, and the smoke says nothing about it. ```bash uv run --no-project python -I scripts/native_update_smoke.py --hash-only ``` -- [ ] 7. script, then CI: the dev-engine bump PR. Open it from a worktree on a branch off `origin/main`. Pick `` from the version of upstream `main`: the command prints the next base. If it prints ``, upstream has not moved on yet: wait, because a dev version of a released base is refused. - - ```bash - curl -fsS https://raw.githubusercontent.com/ArcadeData/arcadedb/main/pom.xml | sed -n '/arcadedb-parent<\/artifactId>/,/<\/version>/ s/.*\(.*\)-SNAPSHOT<\/version>.*/\1/p' - # is that base followed by .dev0 - uv run --no-project python scripts/bump_engine.py --engine --dev-version --check - uv run --no-project python scripts/bump_engine.py --engine --dev-version - ``` - -- [ ] 8. script: refresh the notices the new engine needs. First refresh the kept engine NOTICE (`git -C show :NOTICE > native/wheel/ARCADEDB_ENGINE_NOTICE`; the generated notices embed it). The first `Test native (arcadedb)` run on the bump PR stops at the notices drift check on purpose and uploads the generated file. Download it, commit it, push, and wait for the run to go green. - - ```bash - gh run list -R ArcadeData/arcadedb-python --workflow test-native.yml --branch --limit 1 - gh run download -R ArcadeData/arcadedb-python -n native-build-record-linux-x86_64 -D - cp /THIRD_PARTY_NOTICES.generated.md native/wheel/THIRD_PARTY_NOTICES.md - uv run --no-project python scripts/bump_engine.py --engine --dev-version --check - ``` - -- [ ] 9. CI, then owner: merge the bump PR when every check is green, and delete the branch and the worktree. Then remove the tests and skip-list lines that waited for the new engine: `git grep -n -i "native build links\|native image links"`. - [ ] 10. owner: check the GitHub Release (notes, pre-release flag), add the block "Native wheel speed smoke" to its notes (docs page "Speed smoke of the native wheel", section "What goes into the release notes"; do it again after any re-run of `release-notes.yml`, which rewrites the notes) and, after a final release, that the milestone is closed and what was still open in it moved to the next milestone (the open one due next, or one the workflow created named after the next upstream engine version). If the run failed with a message about the next milestone, create it with a due date and re-run `GitHub Release` (Actions, `workflow_dispatch`, the tag). Close this issue with the two run ids and the two PyPI links. diff --git a/docs/modules/ROOT/pages/development/release.adoc b/docs/modules/ROOT/pages/development/release.adoc index 672995d..52ceea6 100644 --- a/docs/modules/ROOT/pages/development/release.adoc +++ b/docs/modules/ROOT/pages/development/release.adoc @@ -129,6 +129,8 @@ Both channels must carry ``. They are published by different upstream s Each step is a script, CI, or the owner's decision. The owner's tag push is the only step that publishes anything. +For a final release `A.B.C` the dev-engine bump (steps 2 and 3) merges before the tag. The native build of a final tag links the engine of the tag and compares `native/wheel/THIRD_PARTY_NOTICES.md` with it, and only a `-SNAPSHOT` engine skips that comparison, so notices that still name the previous engine stop the build on every platform (https://github.com/ArcadeData/arcadedb-python/issues/547[#547]). The notices and the engine pins move together in one pull request, because a pull request build that links the old engine fails the same comparison against new notices. A `postN` release keeps the engine of its base: skip steps 2 and 3. + [cols="1,4,2"] |=== | Step | What | Who @@ -138,50 +140,50 @@ Each step is a script, CI, or the owner's decision. The owner's tag push is the | script: `scripts/release_preflight.py` | 2 +| Final release only, once the lines `(a)` to `(c)` of the preflight pass and upstream `main` has moved to the next version (<>): the dev-engine bump PR. `scripts/bump_engine.py` moves the pins that dev, PR and nightly builds link: `DEV_ENGINE`, `DEFAULT_VERSION` and the default of the manual-run input `version` in `test-native.yml`, `arcadedb.version` in `native/pom.xml`, the default in `native/scripts/build-image.sh`, and the default of `--version` in `native/wheel/build_wheel.py`. `--check` reports drift and writes nothing; it refuses a `` that `check_version.py` would refuse. +| script: `scripts/bump_engine.py` + +| 3 +| Final release only: the notices of the new engine (below), then the CI of the bump PR, then the merge on green. Then run the preflight again: its line `(e)` must read green runs of `main` on the new engine. +| script, CI, then merge + +| 4 | The go. Zero FAILs, the readiness bar met for a final or post release (the `SKIP` on the variable means the login cannot read it, so check it), and a decision to publish. | owner -| 3 +| 5 | Push the tag, the bare version on the tip of `main`. One tag starts both release workflows. | owner (the only publishing step) -| 4 +| 6 | `release-jvm.yml` and `release-native.yml` validate the tag, build and test the wheels, check them, and publish with trusted publishing. A failed upload is retried by re-running only the publish job. For a final or `postN` release the `pypi` deployment of the native package waits for the owner, and the speed smoke of the native wheel runs before it is approved (xref:development/release-native-smoke.adoc[Speed smoke of the native wheel]). When both have succeeded, `release-notes.yml` creates the GitHub Release and, for a final release, closes the milestone (<<_github_release,GitHub Release>>). | CI -| 5 +| 7 | After-tag verification of both packages: the workflow run and its publish step, the file set and sizes on PyPI, the sha256 of every file against the wheels the workflow checked, and a fresh `uv run --with` install on Python 3.12 and 3.14 that opens a database and runs one SQL and one openCypher query. For the native package, the library hash of the wheel on PyPI is also compared with the one that passed the speed smoke. | script: `scripts/after_tag_verify.sh` and `PACKAGE=native scripts/after_tag_verify.sh`, then `native_update_smoke.py --hash-only` - -| 6 -| The dev-engine bump PR. `scripts/bump_engine.py` moves the pins that dev, PR and nightly builds link: `DEV_ENGINE`, `DEFAULT_VERSION` and the default of the manual-run input `version` in `test-native.yml`, `arcadedb.version` in `native/pom.xml`, the default in `native/scripts/build-image.sh`, and the default of `--version` in `native/wheel/build_wheel.py`. `--check` reports drift and writes nothing; it refuses a `` that `check_version.py` would refuse. -| script: `scripts/bump_engine.py` - -| 7 -| The notices of the new engine (below), then the CI of the bump PR, then the merge on green. -| script, CI, then merge |=== === Commands [source,bash] ---- -# 1. preflight +# 1. preflight (and again after step 3) uv run --no-project python -I scripts/release_preflight.py -# 3. the tag (owner) -git fetch origin main --no-tags && git tag origin/main && git push origin +# 2. the bump (final release only, before the tag) +uv run --no-project python scripts/bump_engine.py --engine --dev-version --check +uv run --no-project python scripts/bump_engine.py --engine --dev-version -# 3a. preview the GitHub Release notes (read-only; a tag that does not exist yet is read as the tip of main) +# 4. preview the GitHub Release notes before the go (read-only; a tag that does not exist yet is read as the tip of main) uv run --no-project python -I scripts/release_notes.py --dry-run -# 5. after the workflows finished (run ids: gh run list -R ArcadeData/arcadedb-python --branch ) +# 5. the tag (owner) +git fetch origin main --no-tags && git tag origin/main && git push origin + +# 7. after the workflows finished (run ids: gh run list -R ArcadeData/arcadedb-python --branch ) scripts/after_tag_verify.sh PACKAGE=native scripts/after_tag_verify.sh - -# 6. the bump -uv run --no-project python scripts/bump_engine.py --engine --dev-version --check -uv run --no-project python scripts/bump_engine.py --engine --dev-version ---- [[_github_release]] @@ -209,7 +211,7 @@ The script only reads (`gh api`, so it needs `gh auth login` or `GH_TOKEN`) and === Choosing the next dev version -A dev version of a released base is refused, so after `` is out the dev line moves to the next base. The next base is the version of upstream `main`, which carries `-SNAPSHOT`: +A dev version of a released base is refused, so the bump of a final release (step 2, before the tag) moves the dev line to the next base. The next base is the version of upstream `main`, which carries `-SNAPSHOT`: [source,bash] ----