Skip to content

fix(e2e): align Windows MXC process container harness - #8388

Merged
apurvvkumaria merged 7 commits into
mainfrom
codex/fix-windows-mxc-openclaw-version-banner
Aug 5, 2026
Merged

fix(e2e): align Windows MXC process container harness#8388
apurvvkumaria merged 7 commits into
mainfrom
codex/fix-windows-mxc-openclaw-version-banner

Conversation

@senthilr-nv

@senthilr-nv senthilr-nv commented Aug 5, 2026

Copy link
Copy Markdown
Collaborator

Summary

Correct the inactive Windows MXC OpenClaw qualification harness for the current process_container contract. The harness now accepts OpenClaw's exact-version banner with a hexadecimal build suffix, relies on isolated CLI state instead of an empty gateway override, and creates the configured one-shot workload without requesting unsupported in-sandbox exec.

Related Issue

Refs #8178

Changes

  • Normalize only parenthesized 7–40 character hexadecimal OpenClaw build suffixes while retaining exact artifact digest checks.
  • Remove OPENSHELL_GATEWAY from the isolated process environment so the explicitly selected test gateway remains authoritative.
  • Create the MXC process_container workload through OpenShell without a trailing exec command.
  • Extend the semantic control-boundary check to reject any Windows MXC sandbox create that requests in-sandbox exec, including multi-create source flows.

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 changes only an inactive, opt-in live qualification harness and its repository guard; no supported CLI, configuration, onboarding workflow, or product behavior changes.
  • 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: Exact-head nine-category security review passed with no findings for 07995f6254f4fac438d418e75f749bc99fe7367b against base b148bc13ee53b7a1f612d07e42275ec732e71877: fix(e2e): align Windows MXC process container harness #8388 (review)
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue:

Documentation Writer Review

  • Documentation writer subagent reviewed the completed changes
  • Result: no-docs-needed
  • Evidence: No supported user-facing surface changed; the inactive harness behavior is covered by focused tests and existing E2E guidance remains accurate.
  • Agent: Codex Desktop

DGX Station Hardware Evidence

  • Tested on DGX Station
  • Tested commit: Not applicable
  • Station profile/scenario: Not applicable
  • Result: Not applicable
  • Supporting evidence: Not applicable

Verification

  • PR description includes a Signed-off-by: line and every commit appears as Verified in GitHub — all 7 commits appear as Verified.
  • Normal pre-commit, commit-msg, and pre-push hooks passed, or npm run validate:pr passed after refreshing origin/main 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/windows-mxc-openclaw-process-container.test.ts test/e2e/support/e2e-semantic-phase-check.test.ts passed 38 tests; npm run test:e2e-phases:check covered 118 tests across 75 files.
  • Applicable broad gate passed — Not applicable; this is a four-file inactive E2E harness and source-shape guard correction covered by the focused project and semantic inventory.
  • 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: Senthil Ravichandran senthilr@nvidia.com

Summary by CodeRabbit

  • Bug Fixes

    • Improved Windows sandbox command validation to detect and reject unsupported in-sandbox execution requests.
    • Refined gateway startup environment handling for more reliable process-container behavior.
    • Improved version parsing to support parenthesized build identifiers while rejecting unsupported local metadata.
  • Tests

    • Added coverage for initial and retry sandbox creation scenarios, gateway selection cleanup, version parsing, and Windows-specific validation boundaries.

Signed-off-by: Senthil Ravichandran <senthilr@nvidia.com>
Signed-off-by: Senthil Ravichandran <senthilr@nvidia.com>
@coderabbitai

coderabbitai Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The change updates Windows MXC process-container helpers and semantic-phase validation. It removes gateway selection from copied environments, normalizes parenthesized revisions, changes sandbox creation arguments, and rejects sandbox creation commands that request in-sandbox execution.

Changes

Windows MXC validation

Layer / File(s) Summary
Process-container environment and command behavior
test/e2e/live/windows-mxc-openclaw-process-container-helpers.ts, test/e2e/support/windows-mxc-openclaw-process-container.test.ts
The helpers remove OPENSHELL_GATEWAY from copied environments, preserve OPENSHELL_GATEWAY_CONFIG, normalize parenthesized hexadecimal revisions, and omit trailing exit arguments during sandbox creation.
In-sandbox execution validation
tools/e2e/check-semantic-phases.mts, test/e2e/support/e2e-semantic-phase-check.test.ts
The validator detects command arguments after --, records execution requests, and reports violations for initial and retry sandbox creation commands.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Possibly related PRs

  • NVIDIA/NemoClaw#8300: Introduced the Windows MXC OpenClaw helpers and semantic-phase validator extended by this change.

Suggested labels: bug-fix

Suggested reviewers: apurvvkumaria

🚥 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
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.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: aligning the Windows MXC process container end-to-end harness with the current contract.
✨ Finishing Touches 💡 1
📝 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-windows-mxc-openclaw-version-banner

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

@github-code-quality

github-code-quality Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Code Coverage Overview

Languages: TypeScript

TypeScript / code-coverage/plugin

The overall coverage in commit 07995f6 in the codex/fix-windows-mx... branch remains at 96%, unchanged from commit b148bc1 in the main branch.

TypeScript / code-coverage/cli

The overall coverage in commit 07995f6 in the codex/fix-windows-mx... branch remains at 82%, unchanged from commit b148bc1 in the main branch.

Show a code coverage summary of the most impacted files.
File main b148bc1 codex/fix-windows-mx... 07995f6 +/-
src/lib/onboard...-transaction.ts 94% 94% 0%
src/lib/sandbox...rce-identity.ts 87% 87% 0%
src/lib/inferen...er-discovery.ts 87% 88% +1%

Updated August 05, 2026 20:57 UTC

@senthilr-nv senthilr-nv self-assigned this Aug 5, 2026
@senthilr-nv senthilr-nv added chore Build, CI, dependency, or tooling maintenance area: e2e End-to-end tests, nightly failures, or validation infrastructure platform: windows Affects native Windows environments integration: openclaw OpenClaw integration behavior v0.0.104 Release target labels Aug 5, 2026
@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

PR Review Advisor — Informational

Advisor assessment: Informational / low confidence
Next action: No advisor follow-up needed.
Findings: 0 blockers · 0 warnings · 0 suggestions
Status: Partial review preserved 0 canonical finding(s) and 2 terminology decision(s) before the advisor stopped.

Model lanes

  • GPT-5.6 Terra (primary): Failed after a partial review · low confidence · 0 blockers · 0 warnings · 0 suggestions
  • Nemotron 3 Ultra (second opinion): Failed

Second-opinion terminology and E2E selections are advisory. They do not change the primary assessment or E2E / PR Gate.

2 semantic terminology decisions

Terminology decisions are advisory. They affect the assessment only when a separate finding identifies concrete semantic impact.

  • established — process_container at test/e2e/support/e2e-semantic-phase-check.test.ts:77: Keep `process_container` as the literal backend contract name.
  • justified — in-sandbox exec at test/e2e/support/e2e-semantic-phase-check.test.ts:77: Keep `in-sandbox exec`; the modifier identifies the guarded command-boundary behavior.

E2E guidance

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

Recommended E2E: cloud-inference, cloud-onboard, security-posture

Workflow run details

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

@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/support/windows-mxc-openclaw-process-container.test.ts (1)

140-142: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick win

Add boundary cases for the parenthesized hexadecimal suffix.

The test covers only the 7-character form. It does not verify the 40-character limit or reject 6-character, 41-character, and non-hex suffixes. Add these cases.

As per path instructions, review tests for behavioral confidence rather than implementation lock-in. Based on the PR objective, the accepted suffix length is 7–40 hexadecimal characters.

Proposed test additions
+    expect(
+      normalizeReportedVersion(
+        "OpenClaw 2026.7.1 (0123456789abcdef0123456789abcdef01234567)\n",
+      ),
+    ).toBe("2026.7.1");
+    expect(normalizeReportedVersion("OpenClaw 2026.7.1 (2d2ddc)\n")).toBeNull();
+    expect(
+      normalizeReportedVersion(
+        "OpenClaw 2026.7.1 (0123456789abcdef0123456789abcdef012345678)\n",
+      ),
+    ).toBeNull();
+    expect(normalizeReportedVersion("OpenClaw 2026.7.1 (2d2ddcZ)\n")).toBeNull();
🤖 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/support/windows-mxc-openclaw-process-container.test.ts` around lines
140 - 142, Extend the normalizeReportedVersion tests to cover parenthesized
hexadecimal suffix boundaries: accept valid 7- and 40-character suffixes, and
return null for 6-character, 41-character, and non-hex suffixes. Keep the
assertions focused on the documented 7–40 hexadecimal character behavior.

Source: Path instructions

test/e2e/support/e2e-semantic-phase-check.test.ts (1)

77-102: 🎯 Functional Correctness | 🔵 Trivial | ⚡ Quick win

Cover the runOpenShellCommand call shape.

Both fixtures call runCommand. validateWindowsMxcControlBoundarySource uses a different argument position for runOpenShellCommand. The production helper uses runOpenShellCommand for sandbox creation at Line 1164. A regression in that branch can pass these tests. Use runOpenShellCommand in one fixture and keep runCommand in the other.

As per path instructions, review tests for behavioral confidence rather than implementation lock-in. Based on the supplied production path, runOpenShellCommand is the call form used by sandbox creation.

Proposed fixture change
-        await runCommand(cli, ["sandbox", "create", "--", "exit"], env, progress, "create");
+        await runOpenShellCommand(["sandbox", "create", "--", "exit"], "create");
🤖 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/support/e2e-semantic-phase-check.test.ts` around lines 77 - 102,
Update the two tests in validateWindowsMxcControlBoundarySource coverage so one
fixture invokes runOpenShellCommand with the sandbox-create arguments and the
other continues using runCommand. Preserve both expected validation errors and
the existing scenarios, ensuring the alternate helper’s argument position is
exercised without changing production behavior.

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.

Inline comments:
In `@test/e2e/live/windows-mxc-openclaw-process-container-helpers.ts`:
- Around line 431-432: Update the environment isolation logic around the
isolated copy to remove every key whose lowercase form is openshell_gateway,
regardless of casing, while preserving OPENSHELL_GATEWAY_CONFIG. In
test/e2e/live/windows-mxc-openclaw-process-container-helpers.ts:431-432, apply
the case-insensitive key filtering; in
test/e2e/support/windows-mxc-openclaw-process-container.test.ts:299-306, add
coverage using a non-empty mixed-case selector and verify the config key
remains.

---

Nitpick comments:
In `@test/e2e/support/e2e-semantic-phase-check.test.ts`:
- Around line 77-102: Update the two tests in
validateWindowsMxcControlBoundarySource coverage so one fixture invokes
runOpenShellCommand with the sandbox-create arguments and the other continues
using runCommand. Preserve both expected validation errors and the existing
scenarios, ensuring the alternate helper’s argument position is exercised
without changing production behavior.

In `@test/e2e/support/windows-mxc-openclaw-process-container.test.ts`:
- Around line 140-142: Extend the normalizeReportedVersion tests to cover
parenthesized hexadecimal suffix boundaries: accept valid 7- and 40-character
suffixes, and return null for 6-character, 41-character, and non-hex suffixes.
Keep the assertions focused on the documented 7–40 hexadecimal character
behavior.
🪄 Autofix

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: a078bef0-37d9-4c07-a484-ee21323993b1

📥 Commits

Reviewing files that changed from the base of the PR and between 3b208d7 and 1bdae1f.

📒 Files selected for processing (4)
  • test/e2e/live/windows-mxc-openclaw-process-container-helpers.ts
  • test/e2e/support/e2e-semantic-phase-check.test.ts
  • test/e2e/support/windows-mxc-openclaw-process-container.test.ts
  • tools/e2e/check-semantic-phases.mts

Comment thread test/e2e/live/windows-mxc-openclaw-process-container-helpers.ts Outdated
senthilr-nv and others added 2 commits August 5, 2026 12:00
Signed-off-by: Senthil Ravichandran <senthilr@nvidia.com>
Signed-off-by: Charan Jagwani <cjagwani@nvidia.com>

@cjagwani cjagwani left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Verdict

Security review — exact head 06c607f38d46bb5b0b584c2032c944b138d4d3f0 against base c6713c9dd17a9682654713ccb6829b8714f1b307: PASS with no findings, subject to every repository merge gate.

Findings Table

No findings.

Detailed Analysis

  1. Secrets and Credentials — PASS. No credential source or value is added. The harness retains the existing host-process allowlist, keeps the readiness token out of command arguments and source literals, and removes only the gateway selector from the isolated child environment.

  2. Input Validation and Data Sanitization — PASS. Reported OpenClaw versions accept only an exact version with an optional parenthesized 7–40 character hexadecimal suffix. Boundary tests accept 7 and 40 characters and reject 6, 41, non-hex, and moving local aliases.

  3. Authentication and Authorization — PASS. No identity, permission, or authorization behavior changes. The selected OpenShell gateway remains authoritative through isolated CLI state.

  4. Dependencies and Third-Party Libraries — PASS. No dependency, package, image, or artifact identity changes. Exact artifact digests and source revisions remain mandatory.

  5. Error Handling and Logging — PASS. The semantic guard fails closed when any process_container create requests an in-sandbox command, including later create calls. No sensitive value is added to errors or logs.

  6. Cryptography and Data Protection — PASS. No cryptographic primitive, key handling, protected-data flow, or retention boundary changes.

  7. Configuration and Security Headers — PASS. Gateway selection removal is case-insensitive for Windows while preserving OPENSHELL_GATEWAY_CONFIG. No network policy, port, privilege, capability, or security-header setting changes.

  8. Security Testing — PASS. Focused E2E-support tests pass 38/38 on the exact head, including gateway-key casing, version boundaries, both OpenShell command helpers, and multiple-create bypass coverage. The semantic inventory passes 118 tests across 75 files. Fresh GitHub CI and protected E2E remain mandatory after the signed base refresh.

  9. System Security — PASS. NemoClaw continues to use OpenShell as the control boundary and does not invoke wxc-exec.exe directly. The change removes unsupported in-sandbox exec from the inactive qualification flow and adds a repository guard against regression.

Files Reviewed

  • test/e2e/live/windows-mxc-openclaw-process-container-helpers.ts
  • test/e2e/support/e2e-semantic-phase-check.test.ts
  • test/e2e/support/windows-mxc-openclaw-process-container.test.ts
  • tools/e2e/check-semantic-phases.mts

Provenance and Required Gates

Issue #8178 explicitly permits the dormant, non-activating qualification harness while keeping native Windows support unapproved. The signed merge refresh preserves all three contributor commits and their Verified status. All four PR commits are Verified. The effective patch has raw SHA-256 b9904e26477bc3f23ac09265180a6e87429a0931746b28d5df141b06f91c824d and stable patch ID 89553648cbccf2cd9f45e4e39c99e670e5e6c369. Documentation writer review passed with no docs needed at this exact head and .agents tree 7320c9e331ddbcd9ff83e0fce9387a004e3bd1aa.

Fresh required CI, protected E2E, unresolved-review resolution, and independent exact-head approval remain mandatory. This review waives none of those gates.

Signed-off-by: Charan Jagwani <cjagwani@nvidia.com>

@cjagwani cjagwani left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Verdict

Security revalidation — exact head 3b0222942507f1996198cbf04c6a431861d34000 against current base 1608281462923ff8282151c7be1a109ee262b4e9: PASS with no findings, subject to every repository merge gate.

Findings Table

No findings.

Detailed Analysis

  1. Secrets and Credentials — PASS. The effective PR patch is unchanged from the prior exact review. The base refresh adds no overlapping secret, credential, environment, or sensitive-logging path.

  2. Input Validation and Data Sanitization — PASS. The reviewed validation and command/path construction are unchanged. The new base delta does not alter an effective PR file.

  3. Authentication and Authorization — PASS. No identity, ownership, permission, or authorization boundary changed in the PR patch or its integration with the refreshed base.

  4. Dependencies and Third-Party Libraries — PASS. The PR's reviewed dependency and artifact identities are unchanged. Base PR #8387 adds verified llama.cpp GGUF acquisition in eight disjoint files and does not change this PR's dependency surface.

  5. Error Handling and Logging — PASS. The reviewed fail-closed behavior and diagnostics are unchanged; the base refresh introduces no overlapping error or logging path.

  6. Cryptography and Data Protection — PASS. The PR's reviewed cryptographic and protected-data behavior is unchanged. No new cross-patch data flow exists.

  7. Configuration and Security Headers — PASS. The effective PR patch preserves its reviewed configuration, network, privilege, capability, port, and header boundaries.

  8. Security Testing — PASS. Raw patch SHA-256 remains b9904e26477bc3f23ac09265180a6e87429a0931746b28d5df141b06f91c824d and stable patch ID remains 89553648cbccf2cd9f45e4e39c99e670e5e6c369. Documentation writer revalidation passed at this exact head with no docs change needed. Prior targeted test evidence remains applicable; fresh exact-head GitHub Actions is authoritative.

  9. System Security — PASS. The signed refresh is conflict-free, preserves the reviewed patch byte-for-byte, and introduces no new runtime trust-boundary interaction with the disjoint base delta.

Provenance and Required Gates

This exact-head revalidation supplements the full prior nine-category review at #8388 (review). It applies the current rubric from .agents tree 7320c9e331ddbcd9ff83e0fce9387a004e3bd1aa.

Fresh required CI, protected E2E, the exact documentation receipt, unresolved-review resolution, GitHub commit verification, and an independent exact-head approval remain mandatory. This review waives none of those gates.

@cjagwani
cjagwani requested a review from cv August 5, 2026 20:25

@cjagwani cjagwani left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Verdict

Security review — exact head 07995f6254f4fac438d418e75f749bc99fe7367b against current base b148bc13ee53b7a1f612d07e42275ec732e71877: PASS with no findings, subject to every repository merge gate.

Findings Table

No findings.

Detailed Analysis

  1. Secrets and Credentials — PASS. The effective PR patch is unchanged and adds no secret, credential source, environment exposure, or sensitive logging. The refreshed base introduces no overlapping credential path.

  2. Input Validation and Data Sanitization — PASS. Reviewed validation, command construction, and path handling remain unchanged. The portable-profile base delta has no exact file overlap with this PR.

  3. Authentication and Authorization — PASS. No identity, ownership, permission, or authorization boundary is widened by the PR patch or its integration with the refreshed base.

  4. Dependencies and Third-Party Libraries — PASS. The PR's reviewed dependency and artifact identities are unchanged. Base PRs #8333 and #8376 add disjoint E2E artifact restoration and portable experimental onboarding behavior.

  5. Error Handling and Logging — PASS. Reviewed fail-closed behavior and diagnostics remain unchanged; the signed integrations add no overlapping error or logging path.

  6. Cryptography and Data Protection — PASS. Reviewed cryptographic and protected-data behavior remains unchanged, with no new cross-patch data flow.

  7. Configuration and Security Headers — PASS. The effective PR patch preserves its reviewed configuration, network, privilege, capability, port, and header boundaries. The hidden portable profile does not bypass this PR's authority checks.

  8. Security Testing — PASS. Raw patch SHA-256 remains b9904e26477bc3f23ac09265180a6e87429a0931746b28d5df141b06f91c824d and stable patch ID remains 89553648cbccf2cd9f45e4e39c99e670e5e6c369. After the intervening E2E artifact-boundary base change, the exact patch and affected base contracts pass 3 files and 72 tests. Exact-head documentation writer revalidation passed; fresh GitHub Actions is authoritative.

  9. System Security — PASS. Both signed refreshes are conflict-free, preserve the effective patch byte-for-byte, and introduce no new runtime trust-boundary interaction. For #7853 specifically, the portable profile supplies onboarding defaults but neither stages messaging credentials nor bypasses registry-driven credential-drift validation.

Provenance and Required Gates

The exact head preserves contributor history through signed merge commits and applies the current rubric from .agents tree 7320c9e331ddbcd9ff83e0fce9387a004e3bd1aa. This supplements the full prior nine-category review at #8388 (review).

Fresh required CI, protected E2E, the exact documentation receipt, unresolved-review resolution, GitHub commit verification, and an independent exact-head approval remain mandatory. This review waives none of those gates.

@apurvvkumaria
apurvvkumaria merged commit e7b50a0 into main Aug 5, 2026
74 of 78 checks passed
@apurvvkumaria
apurvvkumaria deleted the codex/fix-windows-mxc-openclaw-version-banner branch August 5, 2026 23:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: e2e End-to-end tests, nightly failures, or validation infrastructure chore Build, CI, dependency, or tooling maintenance integration: openclaw OpenClaw integration behavior platform: windows Affects native Windows environments v0.0.104 Release target

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants