Skip to content

Correct local Postgres diagnostics and help - #509

Closed
sdairs wants to merge 3 commits into
issue-464-postgres-start-rollbackfrom
issue-465-postgres-diagnostics-help
Closed

Correct local Postgres diagnostics and help#509
sdairs wants to merge 3 commits into
issue-464-postgres-start-rollbackfrom
issue-465-postgres-diagnostics-help

Conversation

@sdairs

@sdairs sdairs commented Aug 24, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Route local Postgres validation and runtime failures through dedicated errors so they never report a ClickHouse execution failure.
  • Honor DOCKER_HOST endpoint selection and give constructor and ping failures platform-aware Docker Desktop or Engine, socket permission, context, and rootless guidance.
  • Correct start help for the versioned data path, all five managed labels, and omitted versus explicit port behavior.
  • Add exact help snapshots plus subprocess fake-Docker coverage for missing sockets, permission failures, daemon-down responses, and missing psql.

Tests

  • cargo test -p clickhousectl (768 passed)
  • cargo test -p clickhousectl --test local_postgres_diagnostics_test (4 passed)
  • cargo test -p clickhousectl --test local_postgres_help_test (2 passed)
  • cargo test -p clickhousectl --test local_postgres_preflight_test (2 passed)
  • cargo fmt --all --check
  • cargo clippy -p clickhousectl --all-targets -- -D warnings
  • cargo build -p clickhousectl

Stack

Position 4 of 4 (top), based on #501.

Closes #465

Stack created with GitHub Stacks CLIGive Feedback

@sdairs sdairs changed the title issue 465 postgres diagnostics help Correct local Postgres diagnostics and help Aug 24, 2026
@sdairs
sdairs force-pushed the issue-465-postgres-diagnostics-help branch from e44f127 to f4e78c4 Compare August 25, 2026 12:11
@sdairs
sdairs force-pushed the issue-464-postgres-start-rollback branch from 3fec2d1 to e1c603b Compare August 25, 2026 12:11
@sdairs

sdairs commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator Author

Addressed the pending feedback in 86dde3f: removed the non-actionable data-path/bind-mount sentence from local postgres start --help and updated its exact snapshot, while retaining the actionable PostgreSQL diagnostics and usage guidance.

Verified with cargo fmt --all --check, the Postgres help snapshot tests (2 passed), local CLI parser tests (43 passed), cargo check -p clickhousectl, and Clippy with warnings denied.

@iskakaushik iskakaushik left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sdairs

sdairs commented Aug 27, 2026

Copy link
Copy Markdown
Collaborator Author

Superseded by #548 in stack #563.

@sdairs sdairs closed this Aug 27, 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.

Correct local Postgres diagnostics and help

2 participants