Repository navigation
fix: keep the full changelog link when a change entry has an unrelated compare url - #1481
Open
qiaobochi040726-source wants to merge 1 commit into
Conversation
qiaobochi040726-source
requested review from
paikend and
yeongseon
as code owners
November 29, 2026 12:22
yeongseon
requested changes
Nov 29, 2026
| notes += "\n" + link + "\n" | ||
| if link: | ||
| url = link.removeprefix("**Full Changelog**: ") | ||
| if url not in body: |
Contributor
There was a problem hiding this comment.
A change entry containing this release's exact compare URL still suppresses the footer here. Please distinguish the standalone canonical footer line from a URL embedded in prose, and cover both cases in the CLI tests.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
scripts/extract_release_notes.pyskipped the**Full Changelog**footer whenever the section body contained any GitHub compare URL, so a normal change entry linking to an upstream comparison silently dropped the canonical link for that release. The check now looks for this release's own compare URL instead, which keeps the old "don't duplicate a footer that is already there" behaviour.Changes
scripts/extract_release_notes.py: compare the canonical URL fromfull_changelog_link()against the body instead of matching any compare URL; the unusedCOMPARE_LINKregex is gone and the docstring says which link counts.test/test_extract_release_notes.py: new case with a foreign compare link in a change entry — the entry keeps its link and the footer is still appended once.Type of Change
Checklist
Docs: not needed - module docstring is the only documentation for this script and it is updated in this changeValidation
uv run --no-project --with pytest --with "sqlalchemy>=2.0" python -m pytest test/test_extract_release_notes.py -q-> 12 passed (11 before).Release-adjacent files as well:
test_extract_release_notes.py test_release_workflows.py test_lint_changelog_sections.py test_check_release_note_quality.py-> 148 passed.Also ran the script by hand on a changelog whose 1.2.0 entry links to
other/project/compare/v9...v10: the entry link stayed and thev1.1.0...v1.2.0footer was appended.Live CUBRID/Alembic evidence: not applicable, release-notes script only.
Related Issues
Closes #1480
Related PRs and precedence: None
Unresolved decision or dependency: None