Skip to content

fix: correct changelog category ordering#1017

Merged
gaborbernat merged 2 commits into
pypa:mainfrom
gaborbernat:fix/changelog-category-ordering
Apr 9, 2026
Merged

fix: correct changelog category ordering#1017
gaborbernat merged 2 commits into
pypa:mainfrom
gaborbernat:fix/changelog-category-ordering

Conversation

@gaborbernat

Copy link
Copy Markdown
Collaborator

Summary

  • Move Bugfixes before Documentation in the 1.4.1 changelog section to match the towncrier type definition order
  • Fix towncrier template to iterate categories using definitions.keys() order (from pyproject.toml) instead of
    section_entries.items() (filesystem-dependent os.listdir() order via split_fragments)

Root cause: towncrier's split_fragments() populates the category dict via setdefault() as it processes fragment
files from os.listdir(). On the CI runner that generated 1.4.1, 980.bugfix.rst was listed after 991.misc.rst,
placing Bugfixes after Miscellaneous.

Closes #1007

Move Bugfixes before Documentation in the 1.4.1 section and fix
the towncrier template to iterate categories in definition order
from pyproject.toml rather than dict insertion order from
os.listdir(), which is filesystem-dependent.

Closes pypa#1007
@gaborbernat gaborbernat force-pushed the fix/changelog-category-ordering branch 2 times, most recently from cd57e51 to 699356d Compare April 9, 2026 21:05
@gaborbernat gaborbernat force-pushed the fix/changelog-category-ordering branch from 699356d to a0cd3cb Compare April 9, 2026 21:18
@gaborbernat gaborbernat merged commit 5cfa1b7 into pypa:main Apr 9, 2026
10 checks passed
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.

Remaining release related CI issue

2 participants