Skip to content

fix: skip authentication for non-interactive commands#402

Open
thde wants to merge 1 commit into
mainfrom
thde/skip-auth
Open

fix: skip authentication for non-interactive commands#402
thde wants to merge 1 commit into
mainfrom
thde/skip-auth

Conversation

@thde
Copy link
Copy Markdown
Member

@thde thde commented May 13, 2026

nctl --help and nctl --version unnecessarily triggered API authentication.

The predictor client for shell completion was created eagerly on every invocation, even when completions weren't being requested. Additionally, --help/--version flags weren't recognized as commands that don't need an API client.

Changes

  • Gate predictor client creation on COMP_LINE: The API client is only created when the shell is actually requesting completions.
  • Skip API client for --help, -h, and --version flags anywhere in the args.

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant