Skip to content

nvx-rs slimming 3.1.2: the cli feature is gone #1107

Closed as not planned
Closed as not planned

Description

Parent: #1083, in #1076. Needs: #1106. Unblocks: #1108, #1109, #1110, #1131.

Leaving code only. Every PR in this group changes only code that this workstream removes from NVX: the cli feature, with the edits that remove references to it. Nothing that stays changes, and no later PR uses what these PRs change, so the size limits for kept code don't apply. Each PR still records its core lines and counted files, and its description opens with this note.

Goal. nvx no longer has a cli feature, and nvx-cli's dependency no longer enables it. The docs.rs features, the diagram generator and the host-layer assertions follow.

PRs, in order. Each PR has one goal, leaves dev green, and names in its description each old test of its area as kept, rewritten or retired, with each change that check_test_changes.py reports. Its tests follow the repository's test layout: a module's unit tests, and the code that only they use, sit in its tests.rs or tests/ and move with it. The estimates count core lines (code, not comments, docs or tests) and counted files; each PR records its measured values. Each PR does what its Scope says and no more: a case, input or layout that its Scope doesn't name, and whatever "Not in this PR" lists, is out of scope. Address every review comment within the scope, and ask before acting on one that asks for more.

  1. SL3.1f: The cli feature is gone.
    • Objective: Once the CLI lives in nvx-cli, nvx no longer needs a cli feature. This PR removes that leaving feature and all references that exist only to support it, while leaving retained behavior untouched.
    • Contents: Leaving code. nvx drops the cli feature, and nvx-cli's dependency no longer enables it. The docs.rs features, the diagram generator and the host-layer assertions follow. The gates in the platforms' new directories go too, and Guest::scratch_template_name loses its gate; SL6.6b moves it to nvx-cli.
    • Scope:
      • Remove cli from nvx's feature table and stop enabling it in nvx-cli's nvx dependency.
      • Remove remaining cfg(feature = "cli") gates, including those in the platform directories, where the guarded code is now required by its real feature.
      • Remove cli from docs.rs configuration, the diagram generator and host-layer dependency assertions.
      • Make Guest::scratch_template_name unconditional until SL6.6b moves it to nvx-cli.
      • Update nvx-rs/tests/host_modules.rs to drop the cli -> sandbox dependency and use another production condition in its two feature-condition fixtures.
    • Not in this PR:
      • Rewriting code that remains in nvx; this leaving-code PR only deletes the feature and references to it.
      • Removing the helpers exposed by SL3.1a through SL3.1c; nvx-cli still calls them until later replacements and moves.
      • Changing the meaning of host, guest, serde, testing or other retained features.
      • Moving scratch_template_name; SL6.6b moves it with artifact discovery.
      • Broad cleanup of manifests, diagrams, platform modules or layering tests beyond removing cli references.
    • Approach: Delete the feature declaration and its enablement, then remove or replace only conditions and assertions that name it. Keep the formerly guarded definitions in place under their actual host or platform conditions; do not refactor retained modules.
    • Done when:
      • nvx builds and tests with each remaining feature set, with no cli feature or cfg(feature = "cli") reference.
      • nvx-cli's tests pass while its nvx dependency enables only the retained features it needs.
      • The host-layer test still detects dependency cycles, and its two condition fixtures still test production conditions.
      • The docs.rs feature list and generated module diagram contain no cli feature.
    • Needs: SL3.1e, in nvx-rs slimming 3.1.1: the old CLI moves into nvx-cli unchanged #1106.
    • Estimate: 20 core lines, 3 counted files.

Tests. nvx-rs/tests/host_modules.rs drops the cli -> sandbox well-known dependency, and its two fixtures that use feature = "cli" as a production condition use another non-test condition, and still prove the same thing. nvx builds and tests with its remaining feature sets, and nvx-cli's tests pass as before.

Done when: every PR above has merged, with dev green.

Activity

  1. esaurez commented on Nov 3, 2026

    @esaurez
    ContributorAuthor

    Closing as not planned: the plan in #1076 changed. nvx stays the only crate, with no Cargo workspace and no new crates. NVX's own programs, its control protocol and the OS layers stay in nvx, private to it, and CI checks the public API against committed snapshots (#1091). The cli feature stays: it builds the nvx-rs binary, and #1091 hides its entry point from the public API.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions