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

feat(action): Improve bug report creation #13397

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

gauthierpetetin
Copy link
Contributor

@gauthierpetetin gauthierpetetin commented Feb 6, 2025

Description

The purpose of this improvement is to automate several steps that I currently do manually when a new release x.y.z is created:

  1. Create regression labels on public code repo (metamask-extension) and private planning repo (MetaMask-planning)
    a. regression-RC-x.y.z
    b. regression-prod-x.y.z
  2. Create bug report issue on planning repo
  3. Add the bug report issue to the Releases Github Project board
  4. Set the RC cut date on the Releases Github Project board.

These steps are important because the data pipelines of our metrics system consume the data that's present on the Releases Github Project board.

Finally this improvement includes a check to no longer re-create the bug report issue when it already exists, which used to happen sometimes when the release was re-cut, and which was disturbing other automations (e.g. wrong metrics, duplicated Slack notifications).

The following prerequisites are already met:

  • Add BUG_REPORT_TOKEN to repo secrets (fine grained access token with Issues:Write and Metadata:Read permissions for metamask-mobile and mobile-planning repos, as well as Projects: Write permissions for MetaMask organization)
  • Add RELEASES_GITHUB_PROJECT_BOARD_NUMBER to repo variables
  • Add RELEASES_GITHUB_PROJECT_BOARD_VIEW_NUMBER to repo variables

Same PR for Extension

Related issues

None

Manual testing steps

  1. Go to this public code repo (equivalent of metamask-extension repo)
  2. Create a new branch with the following format: release/x.y.z (where x, y, z, are numbers)
  3. Wait for 30s, until the Github action execution is finalised
  4. Check that regression-RC-x.y.z and regression-prod-x.y.z labels have been created on the public code repo
  5. Go to this private planning repo (equivalent of MetaMask-planning repo)
  6. Check that regression-RC-x.y.z and regression-prod-x.y.z labels have been created on the private planning repo
  7. Check that the bug report issue has been created on the private planning repo and has the following title: "vx.y.z Bug Report"
  8. Go to this Github Project board
  9. Check that the bug report issue is present on the board and its "RC Cut" date is set to the current date.

In case, you don't have sufficient permissions on these test repos, here's a video where the manual testing steps are demoed.

Screenshots/Recordings

Before

None

After

Pre-merge author checklist

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.

The purpose of this improvement is to
automate several steps when a new release is created: the creation of regression labels on code and planning repos, the creation of bug report issue on planning repo, the addition of the bug report issue to the Releases Github Project board, and the setting of the RC cut date on the Github Project board. Finally this improvement ensures we no longer re-create the bug report issue when it already exists, which can happen when the release is re-cut.
@gauthierpetetin gauthierpetetin added the team-mobile-platform Mobile Platform team label Feb 6, 2025
@gauthierpetetin gauthierpetetin self-assigned this Feb 6, 2025
@gauthierpetetin gauthierpetetin requested a review from a team as a code owner February 6, 2025 22:51
Copy link
Contributor

github-actions bot commented Feb 6, 2025

CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes.

@metamaskbot metamaskbot added the team-extension-platform Extension Platform team label Feb 6, 2025
@gauthierpetetin gauthierpetetin added No QA Needed Apply this label when your PR does not need any QA effort. and removed team-extension-platform Extension Platform team labels Feb 7, 2025
Copy link

sonarqubecloud bot commented Feb 7, 2025

Copy link
Contributor

@Cal-L Cal-L left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
No QA Needed Apply this label when your PR does not need any QA effort. team-mobile-platform Mobile Platform team
Projects
Status: Review finalised - Ready to be merged
Development

Successfully merging this pull request may close these issues.

3 participants