Skip to content

Make CLI command registration compatible with trimming and Native AOT #61

Open

Description

@Anheledir

Part of #26; coordinate JSON work in #60. Unrestricted trimming produced an ~18.0 MB executable and Native AOT ~13.7 MB, but both fail full startup in Spectre.Console.Cli with "Could not get settings type for ... PreferencesCommand". A successful bare version probe is not functional acceptance.

Acceptance

  • Identify reflected command/settings discovery, constructors, converters and generic activation in the current Spectre.Console.Cli dependency.
  • Use supported typed/generated registration, precise preservation/annotations or an upstream fix; document compatibility decisions rather than suppressing unknown warnings.
  • Preserve all commands/options/help/validation, persistent menus, shell exports and quiet/JSON/noninteractive behavior.
  • Re-run strict trimmed/AOT publish plus full startup, settings, JSON, docs/licenses, native credentials, hooks, helper installation/update/rollback on supported native platforms.
  • Record a go/no-go and six-runtime/cross-compilation limits before changing default release settings. Retain the current self-contained fallback until verified.

Activity

  1. added
    enhancementNew feature or request
    P2Follow-up: acceptance, robustness and integrations
    on Oct 26, 2026
  2. Anheledir commented on Oct 26, 2026

    @Anheledir
    OwnerAuthor

    JSON prerequisite #60 is completed in merged #63 (fe00c36). Final native deployment run: https://github.com/Anheledir/SidePulse.NET/actions/runs/40327765391 . Strict partial builds now fail only with Spectre.Console.Cli IL2104 on Windows/Linux/macOS; AOT's remaining IL3050 diagnostics point to the Spectre CommandApp constructor. Application JSON serialization no longer uses reflection fallback. Diagnostic partial-R2R candidates pass the native vault, CLI/provider, docs/licenses, installation and update/rollback smokes on all three platforms. Continue here with the command/settings metadata and dependency compatibility fix; preserve the source-generated contracts and existing wire/schema behavior.

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

    P2Follow-up: acceptance, robustness and integrationsenhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions