Repository navigation
Conversation
🎉 All green!🧪 All tests passed 🎯 Code Coverage (details) 🔗 Commit SHA: 23dea43 | Docs | View more details | Give us feedback! |
d4f60cc to
a1d5314
Compare
|
@codex review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a1d531499d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
🛡️ Codex Security Review · Automatically triggeredSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
The macOS and Windows legs of the orchestrion and otelc integration lanes gate every classifier-matched pull request on 3-vCPU and shared 8-core runners, yet their recent catch record is thin (one macOS job, zero Windows jobs among the last six failing runs) while their cost is the largest in the repository: the otelc macOS leg alone accounts for roughly nineteen runner-hours per day at a 32-minute median (up to 96 minutes). Instead of one file per lane branching inline on the event, each lane now has dedicated files with dedicated events, sharing one lane body: - orchestrion-lane.yml / otelc-lane.yml: the lane body (classifier, matrices, services, tests, joins), a reusable workflow taking an os-list input; the caller's github context flows in, which the classifier and the cross-repository checkout rely on. - orchestrion-pr.yml / otelc-pr.yml: pull requests (and the merge queue for orchestrion) run the ubuntu legs only. - orchestrion.yml / otelc.yml: main-based events (push to main or release-v*, nightly schedule, dispatches, and the cross-repository call for orchestrion) run the full OS matrix, so every merge re-runs the macOS and Windows legs minutes after landing. A new ci-lane-triage.yml workflow turns failures of those main-based legs into deduplicated issues for the apm-go team, closes them when a leg goes green, keeps a pinned tracking issue with each lane's last status, and alerts when a lane goes 26 hours without a run on main. [APMLP-2250]
a1d5314 to
8720221
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 87202210a5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
Ordinary Orchestrion events forward an absent value into a boolean reusable-workflow input, preventing the full matrix from starting. Triage can also miss timeouts, close newer failures on stale successes, and create duplicate issues during overlapping runs.
🤖 Bits Code Review · Commit 8720221
Four review threads on the head commit, all real: - orchestrion.yml forwarded inputs.collect-coverage to the lane's boolean-typed input as an empty value on push, schedule and dispatch runs (the input exists only for workflow_call), which the reusable invocation rejects. It now defaults to false for those events while cross-repository callers keep their value. - Two triage runs finishing close together could both observe that no issue exists and both create it, for the tracking issue and for failure issues of overlapping runs. The script now heals the race after every create: keep the lowest-numbered issue, close the rest as duplicates. - A macOS or Windows leg that exceeded its job timeout is recorded as timed_out, not failure, so a platform-specific hang opened no issue at all. The failure set now includes timed_out. - An older successful run whose triage finished after a newer failure closed the newer issue and announced a recovery that never happened. A green leg now only closes its issue when its run is the lane's latest on main. The four callers also drop secrets: inherit: the lane bodies consume no repository secrets (their credentials come from the OIDC dd-sts action), so least privilege wins. [APMLP-2250]
The failure attribution took the second-newest main-based run as the predecessor, but another run can start before the failing one finishes, which puts the failing run itself (or a newer run) at that index and attributes the regression to the wrong commit. The lookup now finds the triggering run in the list and takes the entry after it. [APMLP-2250]
There was a problem hiding this comment.
More details
The PR moves macOS/Windows integration checks to main-based events, retains Ubuntu checks on PRs, and adds failure triage. Boolean forwarding, missed timeouts, stale recovery, duplicate issues, and incorrect predecessor attribution are addressed. No findings remain open.
🤖 Bits Code Review · Commit c5ea43e
darccio
left a comment
There was a problem hiding this comment.
Changes requested. Additionally:
-
Add CODEOWNERS rules for the two new orchestrion workflow files.
The suffix rule
*orchestrion.ymlno longer matchesorchestrion-lane.ymlororchestrion-pr.yml, so review requests for the 400-line lane body stop reaching @DataDog/apm-orchestrion and the owner check passes either way./.github/workflows/orchestrion-lane.yml @DataDog/apm-orchestrion /.github/workflows/orchestrion-pr.yml @DataDog/apm-orchestrion
…windows-main-only # Conflicts: # .github/workflows/otelc.yml
Dario's 26 review threads, all addressed: - lane-triage.sh: every gh read now goes through a retrying read_gh helper that fails the job loudly instead of swallowing transient API errors; find_issue resolves to the single lowest-numbered open issue; the open loop skips legs a newer completed run already has green, so a recovered regression no longer pings the team; the predecessor lookup skips cancelled and empty conclusions; the status counts and the triage loops share one LEG_WORDS regex and one jobs fetch; the dead BSD date fallback under set -e is gone; the tracking table links issues with #; the tracking body is built once with the footer and a closed tracking issue is reopened instead of duplicated; issues whose legs left the matrix are closed so a Go release bump strands nothing under Open failures. - ci-lane-triage.yml: the header bullets state what the script does; the fork guard no longer claims workflow_call runs. - The PR callers pass the full OS list when the target is a release branch (pull request or queue branch), so a platform regression on a release no longer gates nothing; each PR caller adds a top-level join with the lane's old check name, so a branch protection rule on it keeps resolving. - orchestrion.yml: the dispatch trigger declares the orchestrion-version input the header promised; both main-file headers state the newest-push semantics of the shared concurrency group. The generate-job comment matches its condition again, and the rewrapped matrix comment keeps its indentation. - static-checks.yml: the shellcheck job also covers .github, which is the only lint the triage script has. - Tests: the main-file block asserts no pull_request trigger exists; the queue check uses branchListRunsQueueBranch instead of one exact string; laneOSList fails by name instead of panicking; the queue test comment matches the ungated Ubuntu run; a new test pins the triage workflow_run filter to the lanes' name: values; five stale pointers now name otelc-lane.yml. - AGENTS.md: the lane policy documents the dispatch escape hatch for contributors touching platform-sensitive code. [APMLP-2250]
There was a problem hiding this comment.
The PR separates Ubuntu PR checks from main-based platform coverage and adds triage; earlier findings remain resolved. Open issues are a blocking jq conversion error, retry-output contamination, malformed retired-issue IDs, unfinished-run selection, unsafe cleanup after matrix-expansion failure, and shellcheck being skipped for script-only changes.
🤖 Bits Code Review · Commit 5334310
The retry helper logged to stdout, so a recovered read prefixed its diagnostic to the captured response and every jq parse of it failed; the log goes to stderr now. The job-conclusion map wrapped its entries in an object, which from_entries rejects, so every caller aborted before opening an issue; it takes the entries array directly. The newest-completed selection and the predecessor lookup accepted empty conclusions, so queued and running runs counted as completed; both exclude them now. The retired-leg loop read the whole tab-separated record as the issue number, so the close always failed; it reads the number and the title separately. And leg retirement now requires a successful run: a failed matrix job enumerates no platform jobs, and retiring every issue then would erase the failures the run should have reported. [APMLP-2250]
The shellcheck step that covers .github lives in the lint job, gated by static-lint, while a change confined to lane-triage.sh enabled only static-actions — so a script-only pull request skipped the very lint coverage the step adds. The lane-triage component now enables static-lint as well. [APMLP-2250]
There was a problem hiding this comment.
More details
The PR moves macOS/Windows checks to main-based events, retains Ubuntu PR checks, and adds failure triage. The final lint-gate fix enables shellcheck for script-only PRs; previously reported triage and input-handling defects remain resolved. No findings remain open.
🤖 Bits Code Review · Commit dba052c
…windows-main-only The cache-policy (#5908) and Windows Dev Drive (#5907) changes to the orchestrion and otelc lane bodies are ported into orchestrion-lane.yml and otelc-lane.yml verbatim: the isolated-cache wiring of the integration-test setup-go calls (cache and seed, Windows skipped, the stable-alias seed gates) and the otelc GOCACHE export that puts the instrumented builds into the shared cache. The thin main-based callers stay as this branch wrote them. [APMLP-2250]
The seed-literal counts and the per-OS cache policy test that #5908 added still read the old single-file names; the wiring now lives in orchestrion-lane.yml and otelc-lane.yml. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows coverage to main-based runs, retains Ubuntu PR checks, and adds failure triage; earlier findings remain resolved. Cache-policy tests introduced by the new base still inspect the caller workflows instead of the shared lane files, causing deterministic failures in the static-check gate.
🤖 Bits Code Review · Commit 87ca50d
Three review threads on the propagation rework: - Errexit is disabled inside a command substitution, so the failed assignments in tracking_body and its peers kept rendering and the dashboard edit still succeeded with empty content. Every multi-statement function invoked in a substitution (tracking_body, newest_green_legs, issue_body, commit_line) now runs with an explicit set -e inside it, so a read that exhausts its retries aborts the rendering; a direct assignment of that substitution stops the job before any edit. - The PR callers were missing from joinJobs, so the join-name assertions added last round never executed: deleting either required join still passed the guard. Both callers are listed now and the assertions run. - Reopening a closed issue repairs a stale close only before it happens. The green loop now re-verifies the newest-run guard per close, so a triage that paused while a newer failure completed and triaged no longer closes that failure's reopened issue; the failure path's reopen covers the complementary interleaving. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; loop initialization, dashboard error propagation, and required-check-name assertions are now fixed. Two issues remain: stale recoveries can still close newer failures, and failed issue-body rendering can create empty issues without run links or a team mention.
🤖 Bits Code Review · Commit 629e428
A failed command substitution in an argument position does not stop the command it feeds: gh issue create ran with an empty body when issue_body aborted, losing the run links, the commit and the team mention. The body renders into a checked assignment first, so a failed render stops the job before anything is created. The per-close freshness check still raced the API operations around it: an older green triage could pass it, pause, and close an issue a newer failure had reopened and updated meanwhile. Recovery now reconciles against the issue's own record instead of another freshness check: any run id above this run's, in the body or the comments, means a newer failure spoke on record, and closing would bury it. The complementary interleaving stays covered by the failure path's reopen. [APMLP-2250]
rarguelloF
left a comment
There was a problem hiding this comment.
The CODEOWNERS rules for orchestrion-lane.yml and orchestrion-pr.yml are still missing, so *orchestrion.yml no longer sends them to @DataDog/apm-orchestrion.
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage. Loop initialization, dashboard error propagation, required-check-name assertions, and empty-issue creation are fixed; recovery can still close newer failures after checking history, and failed history reads now permit closing without verification.
🤖 Bits Code Review · Commit e677bfd
RarguelloF's two threads and the bot's two: - The merge-queue push trigger carried a tags-ignore block from the old single-file lane, so release tag pushes like v2.13.0-rc.1 also ran this workflow — a second, ubuntu-only run of every suite on top of the full matrix orchestrion.yml already runs on those tags (the old lane did exactly that this week). The block is gone: the trigger is merge-queue branches only. - The outer join's comment now states the real reason it exists: the lane's own join reports as "lane / <lane> Integration Tests" inside the reusable workflow, which no branch protection rule matches, and it is gated on the classifier while the outer one runs on !cancelled() so the bare name always reports. - The issue-history read converted a failed read into an empty record, which reads as "no newer failure" and closed an issue whose history could not be verified. The read failure now aborts the recovery. - The history check still raced the close that followed it. The close is now reconciled after the mutation too: a newer failure recorded while the close was in flight reopens the issue, and a failure recording after the post-close re-read is covered by its own triage's reopen — every interleaving converges to the newer state. [APMLP-2250]
The commit_line wrappers were inline while the other three used the block form; formatting only, no semantic change — verified by the suites. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; loop inputs, dashboard and issue-body error handling, check-name assertions, and failed history reads are fixed. Two ordering defects remain: late failure comments can leave issues closed, and newer recovery comments can reopen healthy issues.
🤖 Bits Code Review · Commit 532273f
The reconciliation read every run URL in the issue, so a newer
recovery comment ("Green again") read as a newer failure: an older
triage then reopened the healthy issue a newer recovery had already
closed. Only failure records count now — the body's "Failing run"
line and every "Failed again" comment — so recoveries reconcile as
recoveries.
The failure path could also pause between its lookup and its
comment, and a stale recovery could close the issue in that window;
the resumed triage then commented on a closed issue and left it
closed. The failure path now reopens after commenting — a no-op when
the issue is open, and a guarantee that a failure on record always
ends with the issue open. Every interleaving of the two paths now
converges to the newest state.
[APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; failure-comment reopening and recovery-comment filtering address the earlier findings. Two new defects remain: an older failure can reopen an issue after a newer recovery, and ignored reopen errors can leave current failures closed without failing triage.
🤖 Bits Code Review · Commit 38c2de2
The failure path's reopen was unconditional and error-suppressed. An older failure triage could comment, pause while a newer successful triage closed the issue (a real recovery), and then reopen the healthy closed issue. The reopen now skips when a newer run's Green again is on record, and reads the live state first: gh fails a reopen of an open issue, so the no-op case never reaches the error path, while a real reopen failure stops the job instead of reporting success with the failure left hidden. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; reopen failures now propagate, and prior validation and rendering fixes remain intact. One ordering defect remains: an older failure can reopen a healthy issue before the new recovery guard runs, leaving it open despite a newer successful recovery.
🤖 Bits Code Review · Commit bb077c5
The closed-issue branch of the failure path reopened unconditionally: a newer recovery could close the issue after the green-leg snapshot but before this triage's lookup, and that reopen restored the healthy issue before the guarded reopen ever ran. Both failure-path reopens now go through one helper that skips when a newer run's recovery is on record and reopens only a genuinely closed issue. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; earlier rendering, check-name, and API-error fixes remain intact. Both failure-path reopens now share a guard, but an older failure can still reopen a healthy issue when a newer recovery finishes between the history read and the mutation.
🤖 Bits Code Review · Commit 9d82b17
The guarded reopen checked the recovery record, then paused could let a newer success close the issue before the reopen ran, and the reopen restored the healthy issue. The helper now re-reads the record after the reopen and closes the issue again when a newer recovery recorded in the meantime; a recovery recording after that re-read is already covered by the close path's own post-mutation check. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; the earlier reopen race is addressed and prior error-handling fixes remain intact. One ordering defect remains: the new corrective close can use an intermediate recovery to close an issue after a still-newer failure has already been reported.
🤖 Bits Code Review · Commit 318f481
The corrective close accepted any recovery newer than the triggering run, so a failed run whose triage lagged behind a recovery and a still-newer failure closed the current failure issue: fail 100, recover 101, fail 102 — run 100's triage saw 101, closed, and buried 102. The close now compares the newest failure against the newest recovery in the issue's record and closes only when the recovery is the newest record of either kind. [APMLP-2250]
…windows-main-only The otelc pin bump (#5974) lands in the lane body, and the INTEGRATIONS.md and feature-gaps rewrites keep main's new text with the lane-file retargets: OTELC_VERSION, OTELC_MODULES and OTELC_TEST_PACKAGES live in otelc-lane.yml. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; earlier rendering and API-error fixes remain intact. Three issues remain: corrective closes can race newer failures, failed record lookups are swallowed, and post-close reconciliation can reopen issues despite a still-newer recovery.
🤖 Bits Code Review · Commit 693a8d1
Three review threads on the newest-record helpers: - The record lookup's failure inside a command substitution only ended the substitution: read consumed the empty here-string, both ids defaulted to zero, and reconciliation closed an issue whose record could not be read. The lookup is captured with a checked assignment now, so a failed read aborts the job. - issue_has_newer_failure accepted any newer failure, ignoring later recoveries: green 100 closes, fail 101 reopens, green 102 closes — the post-close check reopened on 101 and left the healthy issue open. A newer failure now counts only when it is also newer than the newest recovery. - The corrective close's snapshot could go stale while a failure recorded after it: the close now reconciles after the mutation too, reopening when a newer failure is the newest record. A failure recording after that re-read is covered by its own triage's reopen. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; record-read error propagation, latest-recovery comparison, and the reported corrective-close case are fixed. One ordering defect remains: the added final reopen can override a still-newer recovery and leave a healthy issue open.
🤖 Bits Code Review · Commit 70062a2
The corrective reopen after a stale close had no reconciliation of its own: a recovery recording between its snapshot and the reopen left the healthy issue open. The reopen now re-reads the records and closes again when a recovery is the newest record. One corrective inverse per mutation; the residual write-to-re-read window is covered by the next triage of the recording run. [APMLP-2250]
There was a problem hiding this comment.
The PR moves macOS/Windows checks to main-based runs with issue triage; the reported final-reopen sequence is now reconciled, and earlier error-handling fixes remain intact. One ordering defect remains: the added final close can hide a newer failure whose triage already finished after the history snapshot.
🤖 Bits Code Review · Commit 23dea43
| if [ "$latest_green" -gt "$latest_fail" ] \ | ||
| && [ "$latest_green" -gt "$RUN_ID" ]; then | ||
| log "newer recovery recorded during reopen: closing #$issue" | ||
| gh issue close "$issue" --repo "$REPO" \ |
There was a problem hiding this comment.
Coordinate the final close with newer failure triages
After this snapshot selects recovery 103, failed run 104 can reopen the issue, record its failure, and finish triage before this close executes. The older triage then hides that current failure, with no subsequent reconciliation. A focused mocked ordering reproduced the final closed state. Coordinate issue mutations so an older triage cannot overwrite a newer completed triage; another fixed inverse mutation only moves the race window.
React: 👍 useful · 👎 wrong · 😕 unclear · 👀 right, but not acting on it
What each reaction means
- 👍 Useful: correct, and you're fixing it or will.
- 👎 Wrong: the finding is incorrect, for example the bug can't happen or the code was misread.
- 😕 Unclear: you can't tell what it means or why it matters.
- 👀 Right, not acting: correct, but intended, out of scope for this PR, a known risk, or too minor.
🤖 Bits Code Review · Open Bits AI session
|
/remove |
|
View all feedbacks in Devflow UI.
Done |
What does this PR do?
The macOS and Windows legs of the
orchestrion.ymlandotelc.ymlintegration lanes gate every classifier-matched pull request on 3-vCPU and shared 8-core runners, yet their recent catch record is thin (one macOS job, zero Windows jobs among the last six failing runs) while their cost is the largest in the repository: the otelc macOS leg alone accounts for roughly nineteen runner-hours per day at a 32-minute median (up to 96 minutes).Pull requests and merge-queue branches now run the Ubuntu legs only (release-target pull requests and queue branches keep the full matrix, so a platform regression on a release still runs). The macOS and Windows legs move to main-based events, split into dedicated files with dedicated events around one shared lane body (
orchestrion-lane.yml/otelc-lane.yml):mainre-runs them minutes after landing (superseded runs are cancelled; the nightly is the guaranteed full matrix),A new
ci-lane-triage.ymlworkflow turns failures of those legs into deduplicated issues for the apm-go team (citing the failing commit, the run, and the Datadog CI query), closes them when a leg goes green — only when its run is the lane's newest completed on main — closes issues whose legs left the matrix, keeps a tracking issue with each lane's last status, and alerts when a lane goes 26 hours without a run on main. Every GitHub read in the triage script retries and fails loudly rather than swallowing.The macOS legs stay on the standard arm64 runners in this layer; #5929 (stacked) moves the otelc macOS legs to a larger runner. Ubuntu runs on the shared 8-core larger runner and Windows on the shared
windows-shared-8corefleet, as before.Cost
Measured 2026-11-09 to 2026-11-17: the macOS and Windows legs of both lanes consumed roughly 49 runner-hours per day on pull requests (the otelc macOS leg alone ~19 h/day) for one macOS catch and zero Windows catches. After this PR they run only on main-based events: at the measured ~5 merges per day plus the nightly, that is roughly 3 full-matrix runs per day — about 5 runner-hours — a net reduction of ~44 runner-hours per day, with the trade that a platform regression lands first and is reported by issue instead of blocking the PR. At the before-cost figures the break-even would sit at 12 to 18 merges per day; the intended follow-up is a
changed-componentspush mode that diffsHEAD^1..HEAD, so a merge that does not touch platform-relevant code runs the Ubuntu legs only.Rejected alternatives
Verification
./scripts/lint.sh --action(actionlint)./scripts/lint.sh --misc(copyright, ciselect, citiming, actiontest, checkmake)go test ./scripts/ciselect/ -count=1(incl.TestIntegrationLanesMacWindowsMainOnly, the queue tests, the new filter test)gofmt,go vet,shellcheck(now also over.githubin CI)APMLP-2250
Notes for reviewers
-lane.ymlbodies).Orchestrion Integration Tests,OTelc Integration Tests), so rules on those names keep resolving; theCheck Pull Request CI Statusgate evaluates only the checks that exist.ci-lane-triage.ymlfires onworkflow_runfrom the default branch, so it starts working only after this merges.main(the runner-mapping expression, the step commands), kept verbatim so the move reads as a move.