Skip to content

docs(mxc): clarify mapper schema versions (NVBug 6847154) - #3894

Merged
shailendra-nv merged 1 commit into
NVIDIA:windowsfrom
prekshivyas:fix/nvbug-6847154
Sep 29, 2026
Merged

shailendra-nv merged 1 commit into
NVIDIA:windowsfrom
prekshivyas:fix/nvbug-6847154

Conversation

@prekshivyas

Copy link
Copy Markdown
Contributor

Summary

Clarify why the standalone coarse MXC policy mapper defaults to schema 0.7 while live driver and governed-egress requests use schema 0.8. Investigation showed that these values describe different artifacts and the reported runtime mismatch does not occur.

This PR preserves both behaviors and adds explicit naming, documentation, and regression coverage so the two schema contracts cannot be mistaken for competing live-runtime versions.

Related Issue

  • NVBug 6847154
  • No public GitHub issue required: internal Windows MXC investigation and non-breaking clarification.

Reproduction and conclusion

Before this change, DEFAULT_MXC_VERSION in the coarse mapper was 0.7.0-alpha, while MXC_SCHEMA_VERSION in the driver was 0.8.0-alpha. Code-path and Git-history tracing showed this is intentional:

  • The standalone coarse mapper emits the MXC 0.7 host-list shape with allowedHosts.
  • Governed splits and all live driver requests emit the MXC 0.8 directional shape with egress/ingress.
  • EmbeddedPolicyMapper uses coarse JSON only as an intermediate translation and does not send its version to wxc-exec.
  • The loss report describes the caller-selected coarse artifact, not the live driver.

After this change, the values remain intentionally different, but the coarse constant is explicitly named and the distinct shapes are regression-tested.

Changes

  • Add DEFAULT_COARSE_MXC_VERSION as the clear canonical name for the 0.7 coarse artifact.
  • Retain DEFAULT_MXC_VERSION as a compatibility alias, with no public API break.
  • Clarify the artifact-versus-live scope in the mapper, embedded mapper, and loss-report documentation.
  • Add a regression proving coarse 0.7 uses allowedHosts while governed/live 0.8 uses directional egress.

Testing

  • mise run pre-commit passes
    • Previously attempted on Windows ARM64; the aggregate task is blocked by unchanged host/tooling issues.
  • Unit tests added/updated
    • policy_mapper_matrix: 45 passed.
    • MXC library tests: 114 passed.
  • E2E tests added/updated
    • Real wxc-exec is not installed on this host. The existing ignored dry-run integration remains the real-binary contract check.
  • cargo fmt --all -- --check
  • git diff --check

No speculative preflight comparison was added because wxc-exec --probe does not expose a schema version. That would require a separate MXC interface or dry-run design change.

Checklist

  • Follows Conventional Commits
  • Commits are signed off (DCO)
  • Architecture docs updated (not applicable; code-level API documentation updated)

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

@shailendra-nv shailendra-nv 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.

Reviewed the complete diff and surrounding mapper/live-request code at e889339. No blocking findings. The compatibility alias preserves coarse schema 0.7 while governed output and live requests remain on 0.8. Non-blocking suggestion: assert the literal coarse version in the regression test to catch accidental constant changes. Current checks are successful or skipped; native Windows jobs were skipped, and author-reported native tests were not independently rerun.

@shailendra-nv
shailendra-nv merged commit 20b0ebd into NVIDIA:windows Sep 29, 2026
64 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants