-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: followup to CircleCI Sentry reporting (#27548)
## **Description** Implementing some suggestions from @matthewwalsh0 from #27412 ~Also incorporates changes from @legobeat's #27268~ - Renamed `doNotForceSentryForThisTest` to `doNotForceForThisTest` because the `Sentry` is now implied by the parent property - Abstracted to `addFlagsFromPrBody()` and `addFlagsFromGitMessage()` functions - Only supports one flag right now (`tracesSampleRate`) but it's built to be easily extendable for anything - It's now an incredibly powerful general way to pass runtime flags into the Extension in CircleCI, either through the PR body or through the Git commit message - In either the PR body or the Git commit message, add a line like `flags = {"sentry": {"tracesSampleRate": x.xx}}` If you do both, Git commit message takes precedence - This changes the format from `[flags.sentry.tracesSampleRate: x.xx]` to `flags = {"sentry": {"tracesSampleRate": x.xx}}` Note: This PR, as is, will hit the following error because it's trying to actually parse the sample code above with `x.xx`. The good news is it fails gracefully. ``` Error parsing flags from PR body, ignoring flags SyntaxError: Unexpected token 'x', ..."pleRate": x.xx}}" is not valid JSON ``` [![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/MetaMask/metamask-extension/pull/27548?quickstart=1) ## **Related issues** Followup to: #27412 ## **Manual testing steps** ## **Screenshots/Recordings** ### **Before** ### **After** ## **Pre-merge author checklist** - [x] I've followed [MetaMask Contributor Docs](https://github.com/MetaMask/contributor-docs) and [MetaMask Extension Coding Standards](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/CODING_GUIDELINES.md). - [x] I've completed the PR template to the best of my ability - [ ] I’ve included tests if applicable - [x] I’ve documented my code using [JSDoc](https://jsdoc.app/) format if applicable - [x] I’ve applied the right labels on the PR (see [labeling guidelines](https://github.com/MetaMask/metamask-extension/blob/develop/.github/guidelines/LABELING_GUIDELINES.md)). Not required for external contributors. ## **Pre-merge reviewer checklist** - [ ] I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed). - [ ] I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.
- Loading branch information
1 parent
50dceb5
commit 687cf3a
Showing
7 changed files
with
117 additions
and
45 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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