Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simple configuration for Keep a Changelog style changelogs #693

Merged
merged 4 commits into from
Mar 12, 2025

Conversation

matteosantama
Copy link
Contributor

@matteosantama matteosantama commented Mar 11, 2025

Description

Fixes #691

This PR simplifies the configuration for Markdown changelog files. The directory key is inferred from the name key, and showcontent defaults to true.

Checklist

  • Make sure changes are covered by existing or new tests.
  • For at least one Python version, make sure test pass on your local environment.
  • Create a file in src/towncrier/newsfragments/. Briefly describe your
    changes, with information useful to end users. Your change will be included in the public release notes.
  • Make sure all GitHub Actions checks are green (they are automatically checking all of the above).
  • Ensure docs/tutorial.rst is still up-to-date.
  • If you add new CLI arguments (or change the meaning of existing ones), make sure docs/cli.rst reflects those changes.
  • If you add new configuration options (or change the meaning of existing ones), make sure docs/configuration.rst reflects those changes.

@matteosantama matteosantama requested a review from a team as a code owner March 11, 2025 14:13
@matteosantama matteosantama changed the title Markdown toml array Simple configuration for Keep a Changelog style changelogs Mar 11, 2025
@adiroiban
Copy link
Member

Thanks Matteo for the PR.
It looks good.

Let me know when the PR is ready for review and I will do a full review.

@matteosantama
Copy link
Contributor Author

As it stands this PR closes #691. Would you like to see it include #692 as well, or should that follow in a separate PR?

Copy link
Member

@adiroiban adiroiban left a comment

Choose a reason for hiding this comment

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

Many thanks for the fix.

The change looks good.

A few minor comments.

The major comment is on what is checked/asserted by the tests.

I think that we should check more than just the exit code for build --draft.

Thanks again!

@adiroiban
Copy link
Member

Would you like to see it include #692 as well, or should that follow in a separate PR?

Definetely a separate PR.

We should keep tihs PR as small as possible so that we can merge it as fast as possible.

#692 might need some discussions and considerations before a merge

Thanks

"""
)
self.assertEqual(0, result.exit_code, result.output)
self.assertEqual(expected, news, news)
Copy link
Member

Choose a reason for hiding this comment

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

We can leave it as it is. Just a sidenote

I am not sure that it helps to repeate the actual value here.

Of we want to show full diff, we can set unittest.TestCase.maxDiff

Suggested change
self.assertEqual(expected, news, news)
self.assertEqual(expected, news, news)

Copy link
Member

@adiroiban adiroiban left a comment

Choose a reason for hiding this comment

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

Stellar work! I will merge.

Thanks again

@adiroiban adiroiban merged commit 3af0c53 into twisted:trunk Mar 12, 2025
16 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.

Sane defaults for CHANGELOG.md
2 participants