Skip to content

feat(ci): automate E2E advisor and mock parity - #6583

Merged
cv merged 9 commits into
NVIDIA:mainfrom
prekshivyas:ci/fork-e2e-advisor
Jul 10, 2026
Merged

feat(ci): automate E2E advisor and mock parity#6583
cv merged 9 commits into
NVIDIA:mainfrom
prekshivyas:ci/fork-e2e-advisor

Conversation

@prekshivyas

@prekshivyas prekshivyas commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

Summary

Runs the E2E Advisor for fork PRs in parallel with normal PR CI and adds a deterministic changed-live-test parity gate. Fork analysis executes trusted code from main; new or modified live E2Es must identify a fast PR-collected counterpart or an explicit live-only reason.

Related Issue

Part of #6145.

Changes

  • Add a parallel pull_request_target path for fork PRs while preserving the existing pull_request path for first-party PRs.
  • Bind fork analysis to the triggering head SHA, execute advisor code exclusively from NVIDIA/NemoClaw:main, and remove worktree symlinks before secrets enter the analysis step.
  • Add test/e2e/mock-parity.json as the small live-to-fast mapping manifest.
  • Fail PR and main e2e-support lanes when a new or modified live test lacks a valid fast-test mapping or explicit liveOnlyReason.
  • Validate mapped file existence and ensure counterparts belong to a fast PR-collected Vitest project.
  • Document the changed-file rollout; untouched historical live tests do not require an immediate backfill.

Type of Change

  • Code change (feature, bug fix, or refactor)
  • Code change with doc updates
  • Doc only (prose changes, no code sample modifications)
  • Doc only (includes code sample changes)

Quality Gates

  • Tests added or updated for changed behavior
  • Existing tests cover changed behavior — justification:
  • Tests not applicable — justification:
  • Docs updated for user-facing behavior changes
  • Docs not applicable — justification:
  • Sensitive paths changed (security, policy, credentials, preflight, onboarding, inference, runner, sandbox, or messaging)
  • Sensitive-path review completed or maintainer-approved waiver recorded — reviewer/approval link/justification: The privileged event executes only the workflow and Node implementation from trusted main. PR content is fetched through the base repository pull ref, verified against the event head SHA, stripped of symlinks, and exposed only to repo-confined read-only tools. No PR script, install hook, action, or executable is invoked.
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue:

Verification

  • PR description includes the DCO sign-off declaration and every commit appears as Verified in GitHub
  • Normal pre-commit, commit-msg, and pre-push hooks passed, or npm run check:diff passed when hooks were skipped or unavailable
  • Targeted behavior tests pass for the current change set, or tests are marked not applicable above — 15/15 Advisor boundary tests passed; 4/4 parity behaviors passed; focused PR/main workflow contract passed; the parity CLI passed against the PR diff.
  • Applicable broad gate passed — not applicable; focused workflow and validator tests cover the changed behavior, and normal CI runs the complete Linux e2e-support lane.
  • Quality Gates section completed with required justifications or waivers
  • No secrets, API keys, or credentials committed
  • npm run docs builds without warnings (doc changes only)
  • Doc pages follow the style guide (doc changes only)
  • New doc pages include SPDX header and frontmatter (new pages only)

Signed-off-by: Prekshi Vyas prekshiv@nvidia.com

Summary by CodeRabbit

  • New Features
    • E2E Advisor now supports additional workflow triggers (including fork-safe pull request handling) and posts advisor comments for those runs too.
    • Added an E2E mock parity check to ensure changed live E2E tests match the expected “fast PR” mock contract.
  • Bug Fixes
    • Fixed base/head reference handling for advisor runs, and hardens the workflow by stripping untrusted symlinks before secret-bearing steps.
  • Tests
    • Expanded workflow and parity-check coverage, including updated assertions and new validation tests.
  • Documentation
    • Documented the “changed-file policy” and location of mock-parity.json.
  • Chores
    • Updated workflow permissions and ensured full git history where needed.

@prekshivyas prekshivyas self-assigned this Jul 9, 2026
@prekshivyas prekshivyas added area: ci CI workflows, checks, release automation, or GitHub Actions area: e2e End-to-end tests, nightly failures, or validation infrastructure labels Jul 9, 2026
@coderabbitai

coderabbitai Bot commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

The PR adds pull_request_target handling to the E2E advisor workflow and introduces a mock-parity validation flow for live E2E tests in the PR and main E2E support workflows, with matching tests, docs, and ownership updates.

Changes

Fork PR handling in E2E Advisor

Layer / File(s) Summary
Trigger and job gating
.github/workflows/e2e-advisor.yaml
Adds the pull_request_target trigger and narrows the advise job condition to same-repo pull_request runs, fork pull_request_target runs, or workflow_dispatch.
Target checkout validation and workspace setup
.github/workflows/e2e-advisor.yaml
Extends target checkout to derive event-based target values, validates the fetched head SHA, exports ADVISOR_WORKDIR and PR_NUMBER, and removes symlinks from the analysis workspace.
Advisor refs and comment posting
.github/workflows/e2e-advisor.yaml
Computes BASE_REF and HEAD_REF for pull_request_target in both advisor runs and enables both PR comment steps for pull_request_target events.
Advisor workflow tests
test/e2e-advisor.test.ts
Adds workflow permission assertions and target-checkout/symlink-ordering coverage for the updated advisor flow.

Live E2E mock parity validation

Layer / File(s) Summary
Parity manifest and validator
scripts/checks/e2e-mock-parity.ts
Introduces the mock parity manifest shape, path helpers, validation rules, and CLI entrypoint for checking changed live E2E tests against fast-test mappings or live-only reasons.
Workflow enforcement
.github/workflows/pr.yaml, .github/workflows/main.yaml
Updates the PR and main E2E support workflows to fetch full history and run the parity-check script against the changed commit range before building and testing.
Parity fixtures, tests, and docs
test/e2e/mock-parity.json, test/e2e-mock-parity.test.ts, test/pr-workflow-contract.test.ts, test/e2e/docs/README.md, .github/CODEOWNERS
Adds the mock-parity fixture, Vitest coverage for validateMockParity, workflow contract expectations, documentation for the changed-file policy, a CODEOWNERS rule for the new manifest, and repository layout references.

Estimated code review effort: 4 (Complex) | ~45 minutes

Suggested labels: feature, area: docs

Suggested reviewers: cv

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title is concise and accurately reflects the main CI changes: automating the E2E advisor and mock parity checks.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai 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.

Actionable comments posted: 1

🧹 Nitpick comments (2)
test/e2e-advisor.test.ts (1)

74-78: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low value

Mock gh uses "$*", which loses argument-boundary fidelity.

"$*" joins arguments with a single space, so if any real invocation argument later contains internal whitespace, the logged command and the toContain assertion could pass/fail spuriously without reflecting actual arg boundaries. "$@" piped through a delimiter-aware join (or an array dump) would be more robust, though not required for the current fixed argument set.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/e2e-advisor.test.ts` around lines 74 - 78, The fake gh wrapper in the
test currently logs arguments with "$*", which collapses argument boundaries and
can hide whitespace-related issues. Update the mock command in the test setup to
record arguments using a delimiter-aware approach based on "$@" so each argument
stays distinct when written to FAKE_GH_LOG, keeping the assertions in
test/e2e-advisor.test.ts faithful to the real invocation.
.github/workflows/e2e-advisor.yaml (1)

112-132: 🚀 Performance & Scalability | 🔵 Trivial | ⚡ Quick win

Resolve the PR from the commit directly. GET /repos/{owner}/{repo}/commits/{sha}/pulls already returns PRs associated with that SHA, including open fork PRs; keep the head.repo.full_name/base.repo.full_name filters and the exactly-one check.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/e2e-advisor.yaml around lines 112 - 132, The PR lookup in
the workflow should be resolved directly from the commit SHA instead of listing
all open pulls; update the `gh api` call in the fork-PR resolution step to use
the commit-to-PR endpoint tied to `HEAD_SHA`, then keep the existing `jq`
filters on `head.repo.full_name` and `base.repo.full_name` plus the exactly-one
count check in the same block that sets `pr_number` and `base_ref`.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/e2e-advisor.yaml:
- Around line 96-137: The fork PR lookup in the Resolve fork PR from completed
CI head step is matching github.event.workflow_run.head_sha against
pulls[].head.sha, but for pull_request workflow runs that SHA is the merge
commit, so the lookup can fail. Update the workflow_run handling to resolve the
PR by associated PR number or by a persisted true head SHA from the CI run, and
then use that resolved PR data in the jq filtering and validation logic.

---

Nitpick comments:
In @.github/workflows/e2e-advisor.yaml:
- Around line 112-132: The PR lookup in the workflow should be resolved directly
from the commit SHA instead of listing all open pulls; update the `gh api` call
in the fork-PR resolution step to use the commit-to-PR endpoint tied to
`HEAD_SHA`, then keep the existing `jq` filters on `head.repo.full_name` and
`base.repo.full_name` plus the exactly-one count check in the same block that
sets `pr_number` and `base_ref`.

In `@test/e2e-advisor.test.ts`:
- Around line 74-78: The fake gh wrapper in the test currently logs arguments
with "$*", which collapses argument boundaries and can hide whitespace-related
issues. Update the mock command in the test setup to record arguments using a
delimiter-aware approach based on "$@" so each argument stays distinct when
written to FAKE_GH_LOG, keeping the assertions in test/e2e-advisor.test.ts
faithful to the real invocation.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 66a01c9d-c46e-41f8-bab8-515bea2d79cc

📥 Commits

Reviewing files that changed from the base of the PR and between 4970809 and 884ccf9.

📒 Files selected for processing (2)
  • .github/workflows/e2e-advisor.yaml
  • test/e2e-advisor.test.ts

Comment thread .github/workflows/e2e-advisor.yaml Outdated
@prekshivyas
prekshivyas force-pushed the ci/fork-e2e-advisor branch from 884ccf9 to 5115c9c Compare July 9, 2026 16:55

@coderabbitai coderabbitai 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.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
.github/workflows/e2e-advisor.yaml (1)

1-13: 🔒 Security & Privacy | 🟡 Minor | ⚡ Quick win

Remove the unnecessary issues: write scope

pull-requests: write is enough for the PR comment posting steps here; issues: write is broader than needed for this pull_request_target job.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/e2e-advisor.yaml around lines 1 - 13, The E2E Advisor
workflow is requesting a broader token permission than needed. Update the
permissions block in the E2E / Advisor workflow so the job keeps the PR comment
capability via pull-requests: write but removes the unnecessary issues: write
scope, using the workflow’s permissions configuration near the
pull_request_target setup.

Source: Path instructions

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In @.github/workflows/e2e-advisor.yaml:
- Around line 1-13: The E2E Advisor workflow is requesting a broader token
permission than needed. Update the permissions block in the E2E / Advisor
workflow so the job keeps the PR comment capability via pull-requests: write but
removes the unnecessary issues: write scope, using the workflow’s permissions
configuration near the pull_request_target setup.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: aedb8218-7881-40d3-9572-75f369c342dd

📥 Commits

Reviewing files that changed from the base of the PR and between 884ccf9 and 5115c9c.

📒 Files selected for processing (2)
  • .github/workflows/e2e-advisor.yaml
  • test/e2e-advisor.test.ts
✅ Files skipped from review due to trivial changes (1)
  • test/e2e-advisor.test.ts

Signed-off-by: Prekshi Vyas <prekshiv@nvidia.com>
@prekshivyas
prekshivyas force-pushed the ci/fork-e2e-advisor branch from 5115c9c to 8b0d49c Compare July 9, 2026 17:06
@prekshivyas prekshivyas changed the title feat(ci): run E2E advisor for fork PRs feat(ci): automate E2E advisor and mock parity Jul 9, 2026

@coderabbitai coderabbitai 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.

Actionable comments posted: 2

🧹 Nitpick comments (1)
scripts/checks/e2e-mock-parity.ts (1)

44-108: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Consider extracting per-entry validation into a helper.

validateMockParity mixes manifest-shape validation, per-entry validation, and changed-file cross-checking in one function with several nested branches. Splitting entry validation into a dedicated helper (e.g. validateEntry(entry, fileExists): string[]) would reduce cyclomatic complexity and improve testability of each rule in isolation.

As per coding guidelines, "Keep function complexity low in JavaScript and TypeScript code."

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@scripts/checks/e2e-mock-parity.ts` around lines 44 - 108,
`validateMockParity` is doing manifest validation, per-entry rule checks, and
changed-file cross-checks all in one place, making the function too complex.
Extract the per-entry logic from `validateMockParity` into a dedicated helper
such as `validateEntry(entry, fileExists): string[]`, and have
`validateMockParity` call it for each `MockParityEntry` while keeping the
manifest-shape and changed-file checks separate. Preserve the existing behavior
and error messages, and use the `validateMockParity` and new helper symbols to
keep the rules easy to locate and test.

Source: Coding guidelines

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/main.yaml:
- Around line 173-177: The parity check step in the workflow needs to handle the
zero-SHA base case because github.event.before can be all zeros on the first
push and there may be no valid HEAD~1 base. Update the Validate changed live E2E
mock parity step to detect this case before calling
scripts/checks/e2e-mock-parity.ts, and either skip the check or substitute a
safe existing base ref when BASE_SHA is zero. Use the BASE_SHA env and the
workflow step name to locate the logic.

In `@scripts/checks/e2e-mock-parity.ts`:
- Around line 84-89: The live-only validation in e2e-mock-parity.ts is calling
trim() on entry.liveOnlyReason without first verifying it is a string. Update
the validation around the entry/liveOnlyReason checks to type-check
liveOnlyReason the same way fast is validated, and only call trim() after
confirming it is a string; otherwise push a validation error instead of letting
a TypeError escape.

---

Nitpick comments:
In `@scripts/checks/e2e-mock-parity.ts`:
- Around line 44-108: `validateMockParity` is doing manifest validation,
per-entry rule checks, and changed-file cross-checks all in one place, making
the function too complex. Extract the per-entry logic from `validateMockParity`
into a dedicated helper such as `validateEntry(entry, fileExists): string[]`,
and have `validateMockParity` call it for each `MockParityEntry` while keeping
the manifest-shape and changed-file checks separate. Preserve the existing
behavior and error messages, and use the `validateMockParity` and new helper
symbols to keep the rules easy to locate and test.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: cf3f56f0-f1ae-467e-a0e1-6e45dc46a636

📥 Commits

Reviewing files that changed from the base of the PR and between 5115c9c and 8b0d49c.

📒 Files selected for processing (10)
  • .github/CODEOWNERS
  • .github/workflows/e2e-advisor.yaml
  • .github/workflows/main.yaml
  • .github/workflows/pr.yaml
  • scripts/checks/e2e-mock-parity.ts
  • test/e2e-advisor.test.ts
  • test/e2e-mock-parity.test.ts
  • test/e2e/docs/README.md
  • test/e2e/mock-parity.json
  • test/pr-workflow-contract.test.ts
✅ Files skipped from review due to trivial changes (2)
  • test/e2e/docs/README.md
  • test/pr-workflow-contract.test.ts
🚧 Files skipped from review as they are similar to previous changes (2)
  • test/e2e-advisor.test.ts
  • .github/workflows/e2e-advisor.yaml

Comment thread .github/workflows/main.yaml
Comment thread scripts/checks/e2e-mock-parity.ts

@coderabbitai coderabbitai 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.

🧹 Nitpick comments (1)
test/e2e-advisor.test.ts (1)

272-290: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick win

Consider generalizing the secret-ordering check.

This test only validates ordering for the two hardcoded advisor step names. A future step that references secrets.* before the symlink-removal step wouldn't be caught. Since this is testing a security-relevant workflow contract (secrets shouldn't be exposed to unstripped analysis content), consider scanning all steps for secrets. references and asserting they occur after removeSymlinksIndex, rather than enumerating specific step names.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@test/e2e-advisor.test.ts` around lines 272 - 290, Generalize the
secret-ordering assertion in readAdvisorWorkflow-based test so it checks every
workflow step that references secrets.* instead of only the two hardcoded
advisor steps. Update the logic in the e2e advisor test to scan the steps array,
find any step with secret-bearing env or run content, and assert each such step
appears after the "Remove symlinks from analysis workspace" step. Keep the
existing removeSymlinksIndex lookup and use it as the security boundary for all
secret-consuming steps.

Source: Path instructions

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@test/e2e-advisor.test.ts`:
- Around line 272-290: Generalize the secret-ordering assertion in
readAdvisorWorkflow-based test so it checks every workflow step that references
secrets.* instead of only the two hardcoded advisor steps. Update the logic in
the e2e advisor test to scan the steps array, find any step with secret-bearing
env or run content, and assert each such step appears after the "Remove symlinks
from analysis workspace" step. Keep the existing removeSymlinksIndex lookup and
use it as the security boundary for all secret-consuming steps.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 68ecbf6c-f6ad-4b71-910a-990ebb06e9f4

📥 Commits

Reviewing files that changed from the base of the PR and between e57806f and 972b57c.

📒 Files selected for processing (2)
  • .github/workflows/e2e-advisor.yaml
  • test/e2e-advisor.test.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • .github/workflows/e2e-advisor.yaml

@cv

cv commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

Exact head 29477cdf68c6af3fd3b7ad9442f1f61ad0599e3b now has green ordinary CI on attempt 2, and the exact-head manual E2E Advisor requires no live jobs or targets. The remaining evidence gap is the manual PR Advisor: current main groups all workflow-dispatch reviews into one concurrency slot, so prior #6583 runs were cancelled by unrelated #6589 dispatches; I will retry after the active #6589 run clears.

@cv

cv commented Jul 10, 2026

Copy link
Copy Markdown
Collaborator

Maintainer exact-head follow-up for d566c878:

Nonblocking follow-ups: generalize the secret-ordering contract test to cover every future secrets.* consumer, run a post-merge fork/symlink canary, and monitor paid advisor trigger volume from fork PRs. No change request from this follow-up.

Signed-off-by: Prekshi Vyas <prekshiv@nvidia.com>
Signed-off-by: Prekshi Vyas <prekshiv@nvidia.com>
@prekshivyas

Copy link
Copy Markdown
Collaborator Author

@cv Exact-head rereview requested for c88402a323132e8f94ec6c299b5a35d743c4607f.

I addressed the actionable follow-up from your d566c878 review and closed the exact-head CI issue exposed by the follow-up commit:

  • Generalized the symlink/security ordering contract to scan every workflow step object for secrets.*, rather than hardcoding the two advisor step names. This now protects current and future secret consumers in env, run, with, or other step fields.
  • Fixed PR mock-parity changed-file detection. pull_request.base.sha was stale while Actions checked out a newer synthetic merge, causing base-only main changes to be attributed to this PR. The PR lane now diffs HEAD^1...HEAD^2 (current merge base parent versus actual PR head), with a workflow contract assertion.
  • Reproduced the parity failure using exact failed merge 4b572c6fb9d4c4ff92426a791e1f1fe8d2bcf527; the corrected parent comparison passes against that merge.

Exact-head evidence:

  • Required CI is green: PR workflow attempt 2 and growth guard attempt 2. The retries recovered an unrelated 5-second test timeout and a GitHub Contents API 502 on the unchanged SHA.
  • Trusted PR Advisor run 29107857469 is green on exact head: GPT-5.5 says merge_as_is with no findings; Nemotron reports 0 blockers (one inherent pull_request_target vigilance warning and one optional simplification suggestion).
  • Trusted E2E Advisor run 29107859604 is green with high confidence and requires no live jobs or optional targets.
  • Focused validation: all 10 advisor contract tests pass; the PR parity workflow contract passes; exact failed-merge parity CLI passes; YAML, formatting, repository checks, source-shape, size, secret scan, build, and TypeScript checks pass.
  • All 9 PR commits are GitHub Verified. New commits 93488b2bb and c88402a32 are signed, Verified (reason: valid), and carry DCO trailers; the required DCO check is green.
  • There are 0 unresolved review threads.

Your other two follow-ups are correctly post-merge/operational: the real fork/symlink canary requires the merged main workflow, and paid fork-advisor trigger-volume monitoring requires post-activation traffic. No pre-merge bypass or speculative production change was added for those.

@prekshivyas
prekshivyas requested a review from cv July 10, 2026 16:39
@cv
cv merged commit 8e53609 into NVIDIA:main Jul 10, 2026
42 of 46 checks passed
Hadar301 pushed a commit to Hadar301/NemoClaw-OpenShift that referenced this pull request Jul 12, 2026
<!-- markdownlint-disable MD041 -->
## Summary
Runs the E2E Advisor for fork PRs in parallel with normal PR CI and adds
a deterministic changed-live-test parity gate. Fork analysis executes
trusted code from `main`; new or modified live E2Es must identify a fast
PR-collected counterpart or an explicit live-only reason.

## Related Issue
Part of NVIDIA#6145.

## Changes

- Add a parallel `pull_request_target` path for fork PRs while
preserving the existing `pull_request` path for first-party PRs.
- Bind fork analysis to the triggering head SHA, execute advisor code
exclusively from `NVIDIA/NemoClaw:main`, and remove worktree symlinks
before secrets enter the analysis step.
- Add `test/e2e/mock-parity.json` as the small live-to-fast mapping
manifest.
- Fail PR and `main` `e2e-support` lanes when a new or modified live
test lacks a valid fast-test mapping or explicit `liveOnlyReason`.
- Validate mapped file existence and ensure counterparts belong to a
fast PR-collected Vitest project.
- Document the changed-file rollout; untouched historical live tests do
not require an immediate backfill.

## Type of Change

- [ ] Code change (feature, bug fix, or refactor)
- [x] Code change with doc updates
- [ ] Doc only (prose changes, no code sample modifications)
- [ ] Doc only (includes code sample changes)

## Quality Gates

- [x] Tests added or updated for changed behavior
- [ ] Existing tests cover changed behavior — justification:
- [ ] Tests not applicable — justification:
- [x] Docs updated for user-facing behavior changes
- [ ] Docs not applicable — justification:
- [x] Sensitive paths changed (security, policy, credentials, preflight,
onboarding, inference, runner, sandbox, or messaging)
- [x] Sensitive-path review completed or maintainer-approved waiver
recorded — reviewer/approval link/justification: The privileged event
executes only the workflow and Node implementation from trusted `main`.
PR content is fetched through the base repository pull ref, verified
against the event head SHA, stripped of symlinks, and exposed only to
repo-confined read-only tools. No PR script, install hook, action, or
executable is invoked.
- [ ] Non-success, skipped, or missing CI check accepted by maintainer —
check name, approval link, and follow-up issue:

## Verification

- [x] PR description includes the DCO sign-off declaration and every
commit appears as `Verified` in GitHub
- [x] Normal `pre-commit`, `commit-msg`, and `pre-push` hooks passed, or
`npm run check:diff` passed when hooks were skipped or unavailable
- [x] Targeted behavior tests pass for the current change set, or tests
are marked not applicable above — 15/15 Advisor boundary tests passed;
4/4 parity behaviors passed; focused PR/main workflow contract passed;
the parity CLI passed against the PR diff.
- [ ] Applicable broad gate passed — not applicable; focused workflow
and validator tests cover the changed behavior, and normal CI runs the
complete Linux `e2e-support` lane.
- [x] Quality Gates section completed with required justifications or
waivers
- [x] No secrets, API keys, or credentials committed
- [ ] `npm run docs` builds without warnings (doc changes only)
- [x] Doc pages follow the [style
guide](https://github.com/NVIDIA/NemoClaw/blob/main/docs/CONTRIBUTING.md)
(doc changes only)
- [ ] New doc pages include SPDX header and frontmatter (new pages only)

---
Signed-off-by: Prekshi Vyas <prekshiv@nvidia.com>


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* E2E Advisor now supports additional workflow triggers (including
fork-safe pull request handling) and posts advisor comments for those
runs too.
* Added an E2E mock parity check to ensure changed live E2E tests match
the expected “fast PR” mock contract.
* **Bug Fixes**
* Fixed base/head reference handling for advisor runs, and hardens the
workflow by stripping untrusted symlinks before secret-bearing steps.
* **Tests**
* Expanded workflow and parity-check coverage, including updated
assertions and new validation tests.
* **Documentation**
* Documented the “changed-file policy” and location of
`mock-parity.json`.
* **Chores**
* Updated workflow permissions and ensured full git history where
needed.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Signed-off-by: Prekshi Vyas <prekshiv@nvidia.com>
Co-authored-by: Carlos Villela <cvillela@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: ci CI workflows, checks, release automation, or GitHub Actions area: e2e End-to-end tests, nightly failures, or validation infrastructure

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants