Skip to content

Hide CancellationToken parameters from CLI help output #21

@lex57ukr

Description

@lex57ukr

Goal

Ensure keystone-cli --help output does not expose CancellationToken as a user-facing argument (e.g., --cancellation-token) for any command.

Scope

  • Audit all Cocona command implementations and identify any methods that accept CancellationToken in the signature and therefore surface it in help output
  • Determine the preferred approach:
    • remove CancellationToken from command method signatures where it’s not needed, or
    • suppress/hide it from Cocona-generated help output (if Cocona supports this)
  • Apply the chosen approach consistently across all commands
  • Add a unit test that scans command methods via reflection to enforce the rule:
    • CancellationToken is not present in command method parameters unless it is explicitly suppressed from help output

Outcome

  • CLI help output contains only user-actionable arguments
  • No command lists --cancellation-token (or similar) in help text
  • A regression test prevents this from reappearing in future commands

Notes

  • This is a UX/ergonomics improvement, not a behavior change.
  • If Cocona doesn’t support suppression, standardize on “don’t include CancellationToken in command signatures” and document the convention.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingenhancementNew feature or request

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions