Skip to content

Conversation

@lucas-zimerman
Copy link
Contributor

So far Sentry/JavaScript, Sentry/Capacitor and Sentry/React-Native are using this format, currently the update changelog script is failing due to the presence of this comment session before the ## Unreleased header.

Run /home/runner/work/_temp/ghwf/updater/scripts/update-changelog.ps1 `
Found changelog: /home/runner/work/sentry-react-native/sentry-react-native/CHANGELOG.md
Exception: /home/runner/work/_temp/ghwf/updater/scripts/update-changelog.ps1:40
Line |
  40 |          throw "Unexpected changelog line - expecting a version header …
     |          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | Unexpected changelog line - expecting a version header at this point,
     | such as '## Unreleased', but found: '<!-- prettier-ignore-start -->'
Error: Process completed with exit code 1.

This PR allows those fields to be properly detected and also adds test to it.

Example of changelog with the comment:

# Changelog

<!-- prettier-ignore-start -->
> [!IMPORTANT]
> If you are upgrading to the `1.x` versions of the Sentry SDK from `0.x` or below,
> make sure you follow our [migration guide](https://docs.sentry.io/platforms/SDK/migration/) first.
<!-- prettier-ignore-end -->


## Unreleased

### Features

- Add support for prettier-ignore notes on `CHANGELOG.md` ...

## 2.10.0

@lucas-zimerman lucas-zimerman marked this pull request as ready for review October 15, 2024 19:22
Copy link
Contributor

@vaind vaind left a comment

Choose a reason for hiding this comment

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

Thanks, LGTM with minor nitpicks

Co-authored-by: Ivan Dlugos <6349682+vaind@users.noreply.github.com>
@vaind
Copy link
Contributor

vaind commented Oct 15, 2024

Also, can you add a changelog entry as well?

@lucas-zimerman
Copy link
Contributor Author

Also, can you add a changelog entry as well?

Sure thing

@lucas-zimerman lucas-zimerman requested a review from vaind October 15, 2024 20:04
@krystofwoldrich
Copy link

Thank you @lucas-zimerman

@vaind vaind merged commit 1a3125e into getsentry:main Oct 16, 2024
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.

3 participants