Skip to content

Conversation

@AliSoftware
Copy link
Contributor

@AliSoftware AliSoftware commented Mar 11, 2025

What

This PR introduces a monkey-patch of the Fastlane::Runner#execute_action method to print a ~~~ :fastlane: [lane :#{lane_name}] #{action} collapsible group log output for every action called in your Fastfile.

This will make the Buildkite logs for jobs running fastlane lanes better organized and easier to navigate, as each action will now have its own collapsible section.

Testing

I have created some dummy branches in Tumblr-iOS and WordPress-iOS, making their Gemfile point to this PR's branch of the release-toolkit then triggering a Buildkite build

Tumblr iOS

Buildkite build: https://buildkite.com/automattic/tumblr-ios/builds/32406

image

WordPress iOS

Buildkite build: https://buildkite.com/automattic/wordpress-ios/builds/26131

Compare Buildkite output from before that monkey-patch—but with the ad-hoc patch that has been in WPiOS's Fastfile since a while—with new Buildkite output from the monkey-patch (and with ad-hoc patch in WPiOS's Fastfile removed

image

What's Next

Once this PR lands, we should remove the ad-hoc patch code that was implemented in WPiOS's Fastfile, to use this patch from release-toolkit instead, to avoid WPiOS having double logging of the collapsible group sections in Buildkite.

AliSoftware added a commit to wordpress-mobile/WordPress-iOS that referenced this pull request Mar 11, 2025
@AliSoftware AliSoftware force-pushed the buildkite-aware-logs branch from 7188da6 to b850a4e Compare March 11, 2025 14:22
@AliSoftware AliSoftware marked this pull request as ready for review March 11, 2025 14:22
@AliSoftware AliSoftware self-assigned this Mar 11, 2025
@AliSoftware AliSoftware requested a review from a team March 11, 2025 14:23
@AliSoftware AliSoftware added the enhancement New feature or request label Mar 11, 2025
@AliSoftware AliSoftware enabled auto-merge March 11, 2025 15:21
Copy link
Contributor

@twstokes twstokes left a comment

Choose a reason for hiding this comment

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

Neat!

AliSoftware and others added 3 commits March 12, 2025 20:02
…te logs

Prints a ~~~ collapsible group for every action called in your Fastfile
Co-authored-by: Tanner Stokes <[email protected]>
@AliSoftware AliSoftware force-pushed the buildkite-aware-logs branch from a657efb to 5e7c2d1 Compare March 12, 2025 19:05
@AliSoftware AliSoftware merged commit 4561a32 into trunk Mar 12, 2025
6 checks passed
@AliSoftware AliSoftware deleted the buildkite-aware-logs branch March 12, 2025 19:06
AliSoftware added a commit to wordpress-mobile/WordPress-iOS that referenced this pull request Apr 4, 2025
Now that we've migrated to `release-toolkit` version `13.1`, which includes wordpress-mobile/release-toolkit#638 that already handles inserting Buildkite-aware collapsible groups in CI logs, the custom logic that was added in WPiOS Fastfile only is no longer needed, and in fact duplicated the logs in CI
github-merge-queue bot pushed a commit to wordpress-mobile/WordPress-iOS that referenced this pull request Apr 6, 2025
Now that we've migrated to `release-toolkit` version `13.1`, which includes wordpress-mobile/release-toolkit#638 that already handles inserting Buildkite-aware collapsible groups in CI logs, the custom logic that was added in WPiOS Fastfile only is no longer needed, and in fact duplicated the logs in CI
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants