Skip to content

fix(e2e): load shared exit helper under tsx - #7027

Merged
jyaunches merged 1 commit into
mainfrom
codex/fix-live-vitest-invocation
Jul 16, 2026
Merged

fix(e2e): load shared exit helper under tsx#7027
jyaunches merged 1 commit into
mainfrom
codex/fix-live-vitest-invocation

Conversation

@cjagwani

@cjagwani cjagwani commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

Summary

Restore live E2E execution through the workflow's npx tsx command. The shared helper now loads the root CommonJS exit utility correctly instead of failing every converted live job during module initialization.

Changes

  • Normalize the CommonJS and ESM representations of src/lib/core/process-exit.ts in tools/e2e/live-vitest-invocation.mts. The current consumer is the live E2E workflow introduced by refactor(e2e): route live-Vitest invocations through a validated helper #6996; tsx and Vitest expose the root module differently, so the existing repository interop pattern is required to keep one shared exit-code implementation.
  • Run the helper's subprocess regression coverage through the local tsx executable that npx tsx resolves, protecting the production loader boundary that the previous native Node test did not exercise.

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: This is an internal CI loader fix; the workflow command and all user-facing behavior remain unchanged.
  • 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:
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue:

Verification

  • PR description includes a Signed-off-by: line 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 — npx vitest run --project e2e-support test/e2e/support/live-vitest-invocation.test.ts passed 24 tests; npm run typecheck:cli and Biome also passed.
  • Applicable broad gate passed — npm test for broad runtime/test-harness changes; npm run check for repo-wide validation/coverage changes — not applicable to this focused CI helper fix. The full E2E-support attempt reached five unrelated failures in an unchanged platform-parity shell script under macOS Bash 3.2; the other 41 tests in the diagnostic subset passed.
  • 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: Charan Jagwani cjagwani@nvidia.com

Summary by CodeRabbit

  • Bug Fixes
    • Improved handling of exit codes when running live Vitest commands across different module export formats.
    • Updated end-to-end workflow checks to invoke the CLI consistently, preserving expected failure reporting.

Signed-off-by: Charan Jagwani <cjagwani@nvidia.com>
@cjagwani cjagwani self-assigned this Jul 16, 2026
@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 529c3b1c-afd6-4aab-a0c0-5579f61767ec

📥 Commits

Reviewing files that changed from the base of the PR and between 032d7fa and 94773b8.

📒 Files selected for processing (2)
  • test/e2e/support/live-vitest-invocation.test.ts
  • tools/e2e/live-vitest-invocation.mts

📝 Walkthrough

Walkthrough

The live Vitest invocation tool now supports default and namespace exports from process-exit. Its workflow CLI failure test resolves and runs the tool through the local tsx executable.

Changes

Live Vitest invocation

Layer / File(s) Summary
Normalize process-exit exports
tools/e2e/live-vitest-invocation.mts
The tool normalizes process-exit module shapes before extracting spawnExitCode.
Run failure tests through tsx
test/e2e/support/live-vitest-invocation.test.ts
The test resolves the live Vitest tool and local tsx paths, then invokes the tool through tsx for workflow CLI failure cases.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

Suggested reviewers: laitingsheng

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: fixing the shared exit helper loading path under tsx in the e2e flow.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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 docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/fix-live-vitest-invocation

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

@github-code-quality

Copy link
Copy Markdown
Contributor

Code Coverage Overview

Languages: TypeScript

TypeScript / code-coverage/plugin

The overall coverage remains at 96%, unchanged from the main branch.


Code Coverage is in Public Preview. Learn more and provide us with your feedback.

@github-actions

github-actions Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

PR Review Advisor — Informational

Advisor assessment: Informational / high confidence
Next action: No advisor follow-up needed.
Findings: 0 blockers · 0 warnings · 0 suggestions
Status: No actionable findings remain in the canonical review ledger.

Model lanes

  • GPT-5.6 Terra (primary): Completed · high confidence · 0 blockers · 0 warnings · 0 suggestions
  • Nemotron 3 Ultra (second opinion): Completed · high confidence · 0 blockers · 0 warnings · 0 suggestions
  • Model comparison: normalized findings match; normalized E2E selections differ; severity counts match.

Nemotron output stays in workflow artifacts and does not change the assessment above.

E2E guidance

Advisory only. E2E / PR Gate selects and runs jobs independently.

Recommended E2E: cloud-onboard, credential-sanitization, security-posture

Workflow run details

This automated review informs maintainers. Warnings and suggestions do not require a response. A maintainer decides whether to merge.

@jyaunches
jyaunches merged commit 4168995 into main Jul 16, 2026
73 of 75 checks passed
@jyaunches
jyaunches deleted the codex/fix-live-vitest-invocation branch July 16, 2026 16:30
@wscurran wscurran added area: ci CI workflows, checks, release automation, or GitHub Actions area: e2e End-to-end tests, nightly failures, or validation infrastructure bug-fix PR fixes a bug or regression labels Jul 29, 2026
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 bug-fix PR fixes a bug or regression

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants