Skip to content

Add final-attempt build comparison command - #1049

Merged
mcncl merged 4 commits into
mainfrom
feat/build_compare
Oct 19, 2026
Merged

mcncl merged 4 commits into
mainfrom
feat/build_compare

Conversation

@mcncl

@mcncl mcncl commented Oct 19, 2026

Copy link
Copy Markdown
Contributor

Description

Add bk build compare to compare step outcomes, retry counts and timings without manually inspecting two builds. Use an explicit baseline or default to an earlier successful build on the target branch.

bk build compare 123 --pipeline my-pipeline --json
bk build compare acme/my-pipeline/123 --baseline 120 --text

Changes

  • Compare final attempts using step keys, type, matrix and parallel coordinates. Report name-based matches as heuristic and leave ambiguous jobs unmatched.
  • Return all comparison rows in JSON, YAML or text, including soft-failure flags, retry counts, timings and investigation links. No logs are fetched and comparison does not establish causality or retry safety.
  • Fail without partial comparison output when baseline selection or complete inventory loading fails. Document the bounded searches and unfinished-build snapshot behavior.
  • Preserve configured and command-line no-input/quiet settings, including organization-specific credential selection.

Testing

  • Tests have run locally (with go test ./...)
  • Code is formatted (with go fmt ./...)

@mcncl
mcncl requested review from a team as code owners October 19, 2026 02:06
buildsworth-bk-app[bot]
buildsworth-bk-app Bot previously approved these changes Oct 19, 2026
buildsworth-bk-app[bot]
buildsworth-bk-app Bot previously approved these changes Oct 19, 2026

@buildsworth-bk-app buildsworth-bk-app Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Want to dig deeper?

Paste this into your agent to explore the findings from this review's Buildkite build:

Download the buildsworth logs from build 42255, then answer my questions about the findings.

Install the reading-buildsworth-logs skill to run this.

Comment thread cmd/build/compare.go Resolved
Comment thread cmd/build/compare.go Resolved
@buildsworth-bk-app
buildsworth-bk-app Bot dismissed their stale review October 19, 2026 04:03

Superseded by a newer Buildsworth review.

Widen the API cutoff to retain earlier fractional-second builds while
keeping the precise client-side eligibility check. Clarify that the
scheduled-to-started interval can include upstream waiting.
@buildsworth-bk-app
buildsworth-bk-app Bot dismissed their stale review October 19, 2026 04:11

Superseded by a newer Buildsworth review.

buildsworth-bk-app[bot]
buildsworth-bk-app Bot previously approved these changes Oct 19, 2026
Keep comparison alongside build-wide retries and retain both commands'
coverage. Normalize comparison selectors before selecting credentials,
matching root organization and pipeline selection.
@buildsworth-bk-app
buildsworth-bk-app Bot dismissed their stale review October 19, 2026 04:21

Superseded by a newer Buildsworth review.

@mcncl
mcncl merged commit 0607fe0 into main Oct 19, 2026
2 checks passed
@mcncl
mcncl deleted the feat/build_compare branch October 19, 2026 04:35
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.

1 participant