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

RUM-4079 chore: Migrate dogfooding automation to GitLab #1961

Merged
merged 2 commits into from
Jul 19, 2024

Conversation

ncreated
Copy link
Member

@ncreated ncreated commented Jul 18, 2024

What and why?

📦 🧰 This PR migrates Dogfooding automation to GitLab. It comes with multiple quality of life improvements to streamline our dogfooding process:

  • Dogfooding from develop directly.
  • The sdk_version will now ponit to dogfooded version (e.g. 2.14.1+f3024dc4).
  • Dogfooding PRs will now include CHANGELOG, listing PRs since previous dogfooding.
  • Commits in dogfooding PRs are now signed 🔐 🎁.

It follows other GitLab migration efforts: #1957, #1953, #1945, #1921 and #1910. With this merge, there will be no other meaningful automations remaining in Bitrise.

How?

Dogfooding is a new GitLab stage, which can be started manually for develop commits:

Screenshot 2024-07-18 at 10 43 08

The previous dogfood.py (Python) automation has been replaced with make + dogfood.sh:

  • make dogfood-shopist
  • make dogfood-datadog-app

There are two Python scripts called by dogfood.sh:

  • update-dependency.py - updates Package.resolved in dependant project.
  • read-dogfooded-hash.py - reads last dogfooded commit from dependant project to generate changelog.

Same as before, the dogfooding process is:

  • clone dependant repo
  • update Package.resolved in dependant project
  • commit & push to dogfooding-<dogfooded commit> branch
  • open PR in dependant repo

🎁 New things

We're now dogfooding from develop branch directly, meaning no more merges required to dogfooding branch. The dogfooding can be deleted after we make sure dependant projects no longer need it.

Each PR opened to dependant repo will now include CHANGELOG that lists all PRs merged to dd-sdk-ios since previous dogfooding. See these test PRs:

The sdk_version in dependant projects is now updated to include dogfooded commit hash. This will tell us exactly which SDK version is being used:

349851758-7587ae3d-73cb-4e02-8a19-ad744ad3f72e

^ after round of feedback, this is now using + instead of - to conform with https://semver.org/

In order to make it all work, these two PRs to dependant repos must be merged before we start using it:

Review checklist

  • Feature or bugfix MUST have appropriate tests (unit, integration)
  • Make sure each commit and the PR mention the Issue number or JIRA reference
  • Add CHANGELOG entry for user facing changes

@ncreated ncreated self-assigned this Jul 18, 2024
@ncreated ncreated force-pushed the ncreated/RUM-4079/migrate-dogfooding-automation branch 3 times, most recently from d47d7b3 to 201b402 Compare July 18, 2024 09:12
@ncreated ncreated marked this pull request as ready for review July 18, 2024 09:38
@ncreated ncreated requested review from a team as code owners July 18, 2024 09:38
Copy link
Contributor

@ganeshnj ganeshnj left a comment

Choose a reason for hiding this comment

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

Looks great, couple of suggestion to make it robust to internal working of package.resolved file.

tools/dogfooding/dogfood.sh Show resolved Hide resolved
tools/dogfooding/read-dogfooded-hash.py Outdated Show resolved Hide resolved
tools/dogfooding/dogfood.sh Outdated Show resolved Hide resolved
@ncreated ncreated changed the title RUM:4079 chore: Migrate dogfooding automation to GitLab RUM-4079 chore: Migrate dogfooding automation to GitLab Jul 19, 2024
@ncreated ncreated requested a review from ganeshnj July 19, 2024 09:05
Copy link
Member Author

@ncreated ncreated Jul 19, 2024

Choose a reason for hiding this comment

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

TBC: This script isn't bringing anything new. It's just an extract of the minimal piece from the previous dogfooding model.

Copy link
Contributor

@ganeshnj ganeshnj left a comment

Choose a reason for hiding this comment

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

🚀 great work with quality of life improvements.

@ncreated ncreated merged commit 3a29fdf into develop Jul 19, 2024
17 checks passed
@ncreated ncreated deleted the ncreated/RUM-4079/migrate-dogfooding-automation branch July 19, 2024 16:11
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.

2 participants