Skip to content

[ci-coach] Fix test-unit sync failures: fallback AW files list and OTLP WIF script - #50891

Merged
pelikhan merged 1 commit into
mainfrom
ci-coach/fix-test-unit-sync-failures-ca592fbd7ad999c1
Aug 6, 2026
Merged

[ci-coach] Fix test-unit sync failures: fallback AW files list and OTLP WIF script#50891
pelikhan merged 1 commit into
mainfrom
ci-coach/fix-test-unit-sync-failures-ca592fbd7ad999c1

Conversation

@github-actions

@github-actions github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

CI Optimization Proposal (Pre-flight Repair)

Summary

Pre-flight validation for this run showed test-unit failing (exit 1) while deps-dev, lint, lint-errors, npm-ci, build, and recompile all passed. Two unit tests failed because generated/mirrored files were out of sync with their sources. This PR fixes both by syncing the affected files.

Root Cause & Fix

1. TestFallbackAWFilesMatchesLocalAWDirectory (pkg/cli)

  • Type: Generated data drift
  • Impact: Fails every CI run until fixed; blocks test-unit entirely
  • Risk: None — additive change, no logic altered
  • Changes: Added missing "designer-mappings.md" entry to pkg/cli/data/agentic_workflows_fallback_aw_files.json, matching current .github/aw/*.md contents. The test itself auto-updates this file when the discrepancy is detected; the auto-generated diff was applied.
  • Rationale: A new shared doc file (designer-mappings.md) was added to .github/aw/ without regenerating the fallback JSON snapshot used when the CLI cannot access the network. Keeping this file in sync ensures offline CLI users get the correct workflow file listing.

2. TestExchangeOTLPWorkloadIdentityScriptInSync (pkg/workflow)

  • Type: Mirrored file drift
  • Impact: Fails every CI run until fixed
  • Risk: None — comment-only change, no behavior change
  • Changes: Added the missing // @safe-outputs-exempt SEC-004 ... comment line to pkg/workflow/js/exchange_otlp_workload_identity.cjs so it exactly matches actions/setup/js/exchange_otlp_workload_identity.cjs (the two copies must be byte-identical per the test).
  • Rationale: The exemption comment was previously added only to the actions/setup/js copy but not backported to the pkg/workflow/js copy.

Expected Impact

  • Unblocks test-unit step in CI (currently failing on every run for these two tests)
  • No functional/behavioral changes — both fixes are metadata/comment sync only

Validation Results

Sandbox network access to proxy.golang.org was blocked (403 Forbidden via the sandbox egress proxy), so go test/make test-unit could not be re-run locally in this environment. Both fixes were derived directly from the exact expected-vs-actual diffs captured in the pre-flight test-results.json failure output, and are minimal (1-line additions each) with no ambiguity in what change is required:

  • The JSON diff exactly matches the auto-update the test itself produces.
  • The .cjs files are now byte-identical (verified with diff, no output).

Metrics Baseline

  • Pre-flight validation: test-unit exit_code=1 (2 failing tests) before this change; all other steps (deps-dev, lint, lint-errors, npm-ci, build, recompile) passed.

Warning

Firewall blocked 1 domain

The following domain was blocked by the firewall during workflow execution:

  • proxy.golang.org

To allow these domains, add them to the network.allowed list in your workflow frontmatter:

network:
  allowed:
    - defaults
    - "proxy.golang.org"

See Network Configuration for more information.

Generated by CI Optimization Coach · auto · 54.5 AIC · ⊞ 15.8K ·

  • expires on Aug 8, 2026, 5:59 AM UTC-08:00

- Add missing designer-mappings.md to fallback AW files list
- Sync SEC-004 safe-outputs-exempt comment into pkg/workflow/js copy of exchange_otlp_workload_identity.cjs to match actions/setup/js copy

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Threat detection produced a warning for this pull request output.

These changes need to be scrutinized before merge and only merged after a careful manual review.

@pelikhan
pelikhan marked this pull request as ready for review August 6, 2026 14:37
Copilot AI balanced review requested due to automatic review settings August 6, 2026 14:37
@pelikhan
pelikhan merged commit 95d23e4 into main Aug 6, 2026
10 checks passed
@pelikhan
pelikhan deleted the ci-coach/fix-test-unit-sync-failures-ca592fbd7ad999c1 branch August 6, 2026 14:37
@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor Author

Test Quality Sentinel completed test quality analysis.

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

No test files were added or modified in this PR. Test Quality Sentinel skipped.

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor Author

Design Decision Gate 🏗️ completed the design decision gate check.

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

No ADR enforcement needed: PR #50891 does not have the 'implementation' label and has only 2 new lines of code in business logic directories (threshold: 100).

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor Author

🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

Copilot AI 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.

Pull request overview

Synchronizes generated and mirrored files to restore unit-test consistency.

Changes:

  • Adds designer-mappings.md to the offline fallback file list.
  • Synchronizes the OTLP WIF script’s safe-output exemption comment.
Show a summary per file
File Description
pkg/cli/data/agentic_workflows_fallback_aw_files.json Adds the missing AW document entry.
pkg/workflow/js/exchange_otlp_workload_identity.cjs Matches the canonical setup script.

Review details

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Balanced

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor Author

PR Code Quality Reviewer completed the code quality review.

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

Skills-Based Review 🧠

Applied /diagnosing-bugs — both fixes are exact, minimal sync corrections with no logic changes.

📋 Summary

Changes

  • pkg/cli/data/agentic_workflows_fallback_aw_files.json: adds "designer-mappings.md" to keep the offline fallback list in sync with .github/aw/.
  • pkg/workflow/js/exchange_otlp_workload_identity.cjs: backports the @safe-outputs-exempt SEC-004 comment so both copies remain byte-identical.

Assessment

  • ✅ Root causes correctly identified (file drift, not logic bugs)
  • ✅ Both fixes are the minimal, unambiguous change required
  • ✅ No additional regression tests needed — the existing sync tests serve as regression guards
  • ✅ No behavioral or functional change

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · sonnet46 · 16.4 AIC · ⊞ 7.1K
Comment /matt to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

Both sync fixes are correct and verified:

  • designer-mappings.md exists in .github/aw/ and is now listed in the fallback JSON in correct alphabetical order.
  • The two .cjs copies are byte-identical after adding the @safe-outputs-exempt comment.

No logic or behavioral changes. ✅

🧵 Reviewed using Impeccable skills by Impeccable Skills Reviewer · sonnet46 · 16.9 AIC · ⊞ 5.4K

@github-actions github-actions Bot mentioned this pull request Aug 6, 2026
@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor Author

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

🧪 Test Quality Sentinel Report

Status:No test files to analyze

This PR modifies only non-test files:

  • pkg/cli/data/agentic_workflows_fallback_aw_files.json (data file)
  • pkg/workflow/js/exchange_otlp_workload_identity.cjs (script file)

No test files (Go *_test.go, JavaScript *.test.cjs/*.test.js) were added or modified, so Test Quality analysis is not applicable.

No further test quality review required.

🧪 Test quality analysis by Test Quality Sentinel · haiku45 · 11.9 AIC · ⊞ 7.7K ·
Comment /review to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

✅ Test Quality Sentinel: No test files modified in this PR. Test quality analysis not applicable.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Warning

Threat Detection Engine Failure — The analysis engine could not complete. This is a tooling failure, not a security finding.

What happened

The threat detection engine failed to produce results.

Review the workflow run logs for details.

Verdict: Approve

Trivial, correct sync fix — no blocking issues.

Details

Both changes verified independently:

  • The added "designer-mappings.md" entry to the fallback JSON matches the actual file count in .github/aw/*.md (67 entries in both).
  • The .cjs files in pkg/workflow/js/ and actions/setup/js/ are now byte-identical (verified with diff).

Both are additive, no-behavior-change fixes addressing generated/mirrored file drift caught by unit tests. No correctness, performance, or security concerns in this diff.

🔎 Code quality review by PR Code Quality Reviewer · auto · 13.4 AIC · ⊞ 7.8K
Comment /review to run again

@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown
Contributor Author

🎉 This pull request is included in a new release.

Release: v0.86.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants