Skip to content

Update persist_docs to always validate columns - #798

Merged
koletzilla merged 5 commits into
mainfrom
ClickHouse/persist-docs-validate-columns
Nov 13, 2026
Merged

koletzilla merged 5 commits into
mainfrom
ClickHouse/persist-docs-validate-columns

Conversation

@koletzilla

@koletzilla koletzilla commented Nov 12, 2026 •

Copy link
Copy Markdown
Contributor

Extraction from #717

  • clickhouse__persist_docs now calls dbt's validate_doc_columns before writing column comments, so a column documented in the schema yml that does not exist in the relation produces the same warning as dbt-core's default persist_docs
  • tests/integration/adapter/persist_docs no longer carries its own 2023 copy of the upstream persist_docs base classes and fixtures. It now inherits the classes shipped by dbt-tests-adapter. Also they now run against cloud.

Note

Low Risk
Adds a non-blocking validation warning during docs persistence and refactors tests; no change to comment DDL for valid columns.

Overview
persist_docs for ClickHouse now calls dbt’s validate_doc_columns before applying column comments, so schema yml entries for columns that are not on the relation emit the same warning as core instead of being skipped quietly.

Integration coverage drops the vendored 2023 persist_docs fixtures and bases, and reuses dbt-tests-adapter’s shared test classes (with a higher minimum dev dependency). Release notes and package pins bump dbt-adapters to >=1.22.10 to stay aligned with that stack.

Reviewed by Cursor Bugbot for commit 2a50004. Bugbot is set up for automated code reviews on this repo. Configure here.

@koletzilla koletzilla changed the title Click house/persist docs validate columns Update persist_docs to always validate columns Nov 12, 2026

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 1b1445f. Configure here.

@koletzilla

Copy link
Copy Markdown
Contributor Author

There're flaky tests failing that are unrelated to this PR. I'm checking them separately:

  • tests/integration/adapter/clickhouse/test_clickhouse_errors.py::TestOOMError::test_oom
  • tests/integration/adapter/materialized_view/test_refreshable_materialized_view_external_target.py::TestBasicExternalTargetRefreshableMV::test_create

@koletzilla
koletzilla requested a review from canbekley November 12, 2026 19:03
@canbekley canbekley self-assigned this Nov 12, 2026
@koletzilla

Copy link
Copy Markdown
Contributor Author

There're flaky tests failing that are unrelated to this PR. I'm checking them separately:

  • tests/integration/adapter/clickhouse/test_clickhouse_errors.py::TestOOMError::test_oom
  • tests/integration/adapter/materialized_view/test_refreshable_materialized_view_external_target.py::TestBasicExternalTargetRefreshableMV::test_create

Fixing them here: #799

@canbekley canbekley left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

looks good to me!

@koletzilla
koletzilla merged commit 219d04d into main Nov 13, 2026
27 of 29 checks passed
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.

2 participants