Skip to content

merge release-3.16 into main - #20346

Merged
ywwg merged 24 commits into
mainfrom
owilliams/release-3.16-fixes
Nov 9, 2026
Merged

ywwg merged 24 commits into
mainfrom
owilliams/release-3.16-fixes

Conversation

@ywwg

@ywwg ywwg commented Nov 5, 2026

Copy link
Copy Markdown
Member

Signed-off-by: Owen Williams [email protected]

NONE

ywwg and others added 23 commits October 26, 2026 11:21
…#20162)

Cherry-pick PR #19683 onto release-3.16.

(cherry picked from commit e2e83df)

Signed-off-by: Julien Pivotto <[email protected]>
Co-authored-by: Matthias Loibl <[email protected]>
Also update Release doc.

Signed-off-by: Owen Williams <[email protected]>
Ubuntu 26.04 runners currently ship Docker 29.4.2, whose default seccomp profile blocks socketcall(2) with ENOSYS (actions/runner-images#14790). Since Go on linux/386 still uses socketcall(2) for socket operations (golang/go#79200), all tests opening sockets fail with 'socket: function not implemented' when ubuntu-latest lands on ubuntu-26.04.

Signed-off-by: Bartek Plotka <[email protected]>
…16-pr-references

docs: simplify 3.16 changelog PR references
* Makefile.common: create manifests with buildx imagetools

docker build now attaches provenance attestations, so each per-arch image
is pushed as an OCI index. docker manifest create refuses indexes as
sources, so no multi-arch tags get published.

Signed-off-by: Solomon Jacobs <[email protected]>

* Makefile.common: fail docker targets on the first error

The docker recipes run in a single shell loop, so only the exit status of
the last command was reported. Failed manifest pushes went unnoticed while
the publish job stayed green.

Signed-off-by: Solomon Jacobs <[email protected]>

* Revert "Makefile.common: fail docker targets on the first error"

This reverts commit d4ff4e8.

Signed-off-by: Solomon Jacobs <[email protected]>

---------

Signed-off-by: Solomon Jacobs <[email protected]>
Signed-off-by: Owen Williams <[email protected]>
build: create manifests with buildx imagetools (#20229)
Properly bump changelog version number, and create a new small script to do that as part of the release process.
Also creates a new bump-versions makefile target so this is easy to do.

Signed-off-by: Owen Williams <[email protected]>
release-3.16: properly bump changelog version
Signed-off-by: Owen Williams <[email protected]>
@ywwg
ywwg marked this pull request as ready for review November 5, 2026 16:28
@ywwg
ywwg requested review from a team, Nexucis, SuperQ, juliusv and simonpasquier as code owners November 5, 2026 16:28

@aknuds1 aknuds1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I found some changelog problems. There might be some issues with the script too.

Comment thread CHANGELOG.md Resolved
Comment thread CHANGELOG.md Resolved
Comment thread CHANGELOG.md Resolved

@aknuds1 aknuds1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I opened a PR to your branch, where I propose fixes to the bump_changelog_version.sh script along with a regression test suite. PTAL.

…20356)

* docs: drop released entries from the unreleased changelog section

The three entries in the "main / unreleased" section are all released
already, so they would be listed again in the next release notes:

- the exporter-toolkit HTTP/2 fix is in 3.16.0 as #19848 (the entry cited
  #19807, which is the issue, not the PR),
- the promtool --allow-incompatible-block-duration entry is in 3.16.0 as
  #19363,
- the sigv4 v0.5.0 upgrade is in 3.15.0 as #19569.

Also reword the two subquery statistics entries in the 3.16.0 section so
they no longer contradict each other: subqueries contribute their
underlying sample consumption to TotalSamples, while #19873 stopped
counting their materialized results a second time.

* chore: make the release version bump refuse unsafe rewrites

The script replaced the first non-"main / unreleased" heading in
CHANGELOG.md no matter which release it belonged to. If the generated
release notes had not been pasted in yet, or a stale tree was used, the
previous release's heading was silently relabelled instead of the script
failing. The "no release heading found" guard never fired either, since a
real CHANGELOG.md always has a heading.

The heading is now only rewritten when it belongs to the version in the
VERSION file, including the pre-release heading that a final release
promotes in place: bumping 3.16.0-rc.4 to 3.16.0 renames
"## 3.16.0-rc.4" rather than adding a section, which makes the script
reproduce the hand-made 3.16.0 release commit byte for byte. A heading
for an already tagged version is refused too, since re-dating a released
section is the same kind of corruption; only local tags are visible to
that check, and it is skipped outside a git repository. Every refusal
exits non-zero with a single message and leaves CHANGELOG.md untouched.

The recorded date no longer depends on when the script happens to run:
--date sets it, the date is validated against the calendar in bash rather
than by relying on whether the local date(1) understands -d or -f, and an
empty or missing value is rejected. Whitespace and a CR left in VERSION
are stripped before the optional "v" prefix, and the rewritten heading
keeps the line ending of the file, so a CRLF checkout does not end up
with mixed endings.

Run the changelog step before ui-bump-version in the bump-versions target
so a refusal leaves the working tree untouched instead of half-applied,
and pass the release date through it with make bump-versions
RELEASE_DATE=..., which RELEASE.md now documents next to the date bullet
it supersedes.

* test: add regression tests for bump_changelog_version.sh

The script has no coverage, and the release flow is only exercised a
handful of times per year, so a wrong heading is likely to be noticed
after the notes are published.

Each case builds a throwaway tree with a VERSION file and a CHANGELOG.md,
runs the script in it, and asserts the exit status, the resulting newest
release heading, that a refusal leaves CHANGELOG.md untouched, that a
successful run rewrites the heading and nothing else, and that no
temporary file is left behind. A CRLF changelog must also stay CRLF end
to end.

The cases cover every heading transition the 3.16 release performed, that
is rc.N to rc.N+1 and rc.N to the final version, one of them replayed
from the recorded history (815458a's "## 3.16.0-rc.2" heading with
VERSION 3.16.0-rc.4 must produce e7d153c's "## 3.16.0-rc.4" heading),
plus the previous-release relabelling that motivated the hardening,
already tagged versions, a tag for a different version, whitespace and a
"v" prefix in VERSION, calendar-invalid dates, the default release date,
a changelog without a "main / unreleased" heading as main looked after
the 3.14 merge, and the argument errors.

The cases run below a GIT_CEILING_DIRECTORIES boundary, since git would
otherwise report the tags of an enclosing repository and trip the
already-tagged guard. The two tag cases are skipped when git is not on
PATH, and the bump-versions case is skipped when make is not available,
so make test still works from a source tarball or a minimal image.

The bump-versions case reads `make -n bump-versions` to check that the
changelog step runs before ui-bump-version, so a refusal leaves the tree
untouched, and that RELEASE_DATE reaches the script when given and is
omitted otherwise.

Run them with make test-scripts, which make test and the required "Check
generated parser" CI job now call, so a regression fails CI instead of
being found at release time.

* chore: verify that the CHANGELOG heading matches VERSION

Release branches drift when VERSION is bumped without bumping the newest
CHANGELOG heading: 3.16.0-rc.3 was tagged while its released notes still
said 3.16.0-rc.2, which is what the rest of this tooling exists to avoid.
That invariant is decidable from two files without writing anything, so
check it directly instead of relying on whoever runs the bump to get it
right.

--check verifies that the newest release heading matches the version in
VERSION, writes nothing, and exits non-zero on a mismatch. The "Check
release notes" workflow now runs it for pull requests to main and the
release branches, so the drift fails the PR rather than being published:
it is the only change that would have caught the rc.3 tag by itself.

Rename the usage output accordingly and cover the new mode in the script
tests, including the recorded rc.2/rc.3 mismatch from the 3.16 release.

* chore: trim the release version bump hardening

Following review, drop the safeguards that only defend against mistakes
a release shepherd would see in the release PR's diff: the calendar
validation of the date, the already-tagged guard, CRLF and whitespace
handling, the --date flag with RELEASE_DATE, and the branch-protection
note in RELEASE.md. Also drop checks that a later check already covers,
and run the one test file directly instead of globbing for test files.

Keep the refusal to relabel another release's heading and the --check
mode run in CI, since v3.16.0-rc.3 was tagged with an rc.2 heading
without anyone noticing. Both modes now parse the newest heading once;
the bump decides in bash whether the heading is ours and then rewrites
it with the original awk one-liner. --check validates the date with a
YYYY-MM-DD pattern, which is enough to catch the placeholder that
generate_release_notes.sh emits. The VERSION format check stays: without
whitespace stripping, it is what refuses a VERSION with a trailing space
or CR, which --check would otherwise accept.

Run --check only on pull requests to the release branches, which is
where releases are tagged from; on main, drift would fail every
unrelated pull request until someone fixed it.

The test suite shrinks to nine cases: the heading transitions a release
performs, the refusals, and the --check outcomes.

---------

Signed-off-by: Arve Knudsen <[email protected]>

@aknuds1 aknuds1 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@ywwg
ywwg merged commit cdca566 into main Nov 9, 2026
40 checks passed
@ywwg
ywwg deleted the owilliams/release-3.16-fixes branch November 9, 2026 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants