Skip to content

Validate local client selectors and ports - #492

Open
sdairs wants to merge 1 commit into
issue-474-stop-remove-name-flagfrom
issue-466-local-client-selectors
Open

Validate local client selectors and ports#492
sdairs wants to merge 1 commit into
issue-474-stop-remove-name-flagfrom
issue-466-local-client-selectors

Conversation

@sdairs

@sdairs sdairs commented Aug 24, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • reject --name with --host or --port at Clap parsing time, regardless of argument order
  • reject client port zero while retaining ports 1 and 65535
  • preserve and document ClickHouse direct-mode defaults: host-only uses port 9000 and port-only uses localhost
  • apply the same selector and client-port validation to the analogous local Postgres client
  • cover selector matrices and real subprocess behavior with isolated fake binaries

Closes #466

Verification

  • cargo test -p clickhousectl local::cli::tests::client_ (3 passed)
  • cargo test -p clickhousectl --test local_client_selectors_test (2 passed)
  • cargo test -p clickhousectl (750 passed across unit and integration tests)
  • cargo fmt --all --check
  • cargo clippy -p clickhousectl --all-targets -- -D warnings

Stack

@sdairs sdairs changed the title Validate local client selectors Validate local client selectors and ports Aug 24, 2026
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.

1 participant