Skip to content

Revert "Merge pull request #96194 from scanhex12/add_schema_s3_check" - #99339

Merged
kssenii merged 1 commit into
masterfrom
revert-s3-schema-validation
Mar 13, 2026
Merged

kssenii merged 1 commit into
masterfrom
revert-s3-schema-validation

Conversation

@kssenii

@kssenii kssenii commented Mar 12, 2026 •

Copy link
Copy Markdown
Member

This reverts commit 584f3ac, reversing changes made to 7dbecb0.

Closes: #99190

Changelog category (leave one):

  • Not for changelog (changelog entry is not required)

Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):

...

Documentation entry for user-facing changes

  • Documentation is written (mandatory for new features)

Note

Medium Risk
Removes CREATE-time remote schema consistency validation for object-storage tables/functions, which can change when invalid schemas are accepted and shift errors to query time. Affects S3/Hive partitioning behavior and related test expectations.

Overview
Reverts the previously-added remote schema consistency check for object-storage engines during CREATE TABLE when a structure is explicitly provided.

validateColumns is removed and replaced with a narrower validateSupportedColumns check (only rejects non-ordinary columns), and StorageObjectStorage now skips any remote schema probing/column-existence validation when schema/format are already specified.

Tests are updated accordingly: the integration test_check_parquet_schema is removed, and the hive partitioning stateless test now expects table creation with a partition-only schema to succeed when use_hive_partitioning=0 (with follow-up query expectations adjusted).

Written by Cursor Bugbot for commit adcc593. This will update automatically on new commits. Configure here.

Version info

  • Merged into: 26.3.1.653
  • Backported to: 26.2.5.26

@clickhouse-gh

clickhouse-gh Bot commented Mar 12, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [adcc593]

Summary: ✅


AI Review

1) Summary

This PR reverts #96194 behavior that validated user-declared object-storage schemas against remote file schemas at CREATE time, and restores prior behavior where unsupported special columns are rejected but remote consistency checks are not performed at create-time. I did not find blocker/major correctness, safety, concurrency, or performance issues in the reverted code paths; overall verdict is approve.

2) Missing context (if any)

  • Full CI signal is incomplete in the Praktika report snapshot (result_pr.json currently contains no finalized test entries), so end-to-end pass/fail evidence is not yet available from that source.
  • No benchmark artifacts were provided for this PR (expected for a revert of validation logic, but still absent).

3) Findings (by severity)

Blockers

  • None.

Majors

  • None.

PR looks good; no inline code comments were posted because there were no actionable blocker/major findings.

4) Tests & Evidence

  • Evidence reviewed: PR diff (6 files), CI robot report link (https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=99339&sha=latest&name_0=PR), and changed test expectations.
  • Coverage impact: one integration test (test_check_parquet_schema) is removed as part of the revert; stateless coverage in 03363_hive_style_partition is updated to assert deferred error timing (UNKNOWN_IDENTIFIER at query time instead of BAD_ARGUMENTS at CREATE).
  • Negative/error-handling tests: present in stateless test updates (INCORRECT_DATA and UNKNOWN_IDENTIFIER paths).
  • Optional follow-up (non-blocking): reintroduce a lightweight integration assertion that explicitly documents the new/old expected failure phase (create-time vs read-time) for Parquet/S3.

5) ClickHouse Compliance Checklist (Yes/No + short note)

  • Data deletions logged? N/A (no deletion-path changes).
  • Serialization formats versioned? Yes/N/A (no serialization format changes).
  • Experimental setting gate present? N/A (no new feature introduced; behavior is a revert).
  • Settings exposed for constants/thresholds? N/A (no new constants introduced).
  • Backward compatibility preserved? Yes (revert restores earlier behavior).
  • SettingsHistory.cpp updated for new/changed settings? N/A (no settings changes).
  • Existing tests untouched (only additions)? No (one integration test removed; one stateless test adjusted) — consistent with explicit revert scope.
  • Docs/user-facing notes updated? N/A (revert, changelog marked not required).
  • Core-area change got extra scrutiny? Yes (object-storage schema resolution/validation path reviewed).

6) Performance & Safety Notes

  • Hot-path impact: neutral-to-positive at CREATE time (remote schema probe removed); query-time behavior may surface identifier exceptions later.
  • Memory/concurrency/resource safety: no new ownership or synchronization risks introduced in this revert.
  • Benchmarks: none provided; minimal reproducible check if desired: measure latency difference for CREATE TABLE ... ENGINE=S3(...) with explicit schema over high-latency object storage before/after revert.

7) User-Lens Review

  • Behavior is understandable if documented: table creation can now succeed with partial/mismatched explicit schema, and some errors move to query execution.
  • Error surfacing remains actionable (UNKNOWN_IDENTIFIER for missing columns), but timing changes may surprise users expecting strict create-time validation.

8) Final Verdict

  • Status: Approve
  • Minimum required actions: none.

@clickhouse-gh clickhouse-gh Bot added the pr-not-for-changelog This PR should not be mentioned in the changelog label Mar 12, 2026
@clickhouse-gh

clickhouse-gh Bot commented Mar 12, 2026

Copy link
Copy Markdown
Contributor

LLVM Coverage Report

Metric Baseline Current Δ
Lines 83.80% 83.80% +0.00%
Functions 23.90% 23.90% +0.00%
Branches 76.30% 76.30% +0.00%

PR changed lines: PR changed-lines coverage: 71.43% (15/21)
Diff coverage report
Uncovered code

@kssenii
kssenii added this pull request to the merge queue Mar 13, 2026
@nikitamikhaylov nikitamikhaylov self-assigned this Mar 13, 2026
Merged via the queue into master with commit 3ddea05 Mar 13, 2026
160 checks passed
@kssenii
kssenii deleted the revert-s3-schema-validation branch March 13, 2026 11:33
@robot-clickhouse robot-clickhouse added the pr-synced-to-cloud The PR is synced to the cloud repo label Mar 13, 2026
@robot-ch-test-poll robot-ch-test-poll added the pr-must-backport-synced The `*-must-backport` labels are synced into the cloud Sync PR label Mar 13, 2026
robot-clickhouse added a commit that referenced this pull request Mar 13, 2026
@robot-ch-test-poll robot-ch-test-poll added the pr-backports-created Backport PRs are successfully created, it won't be processed by CI script anymore label Mar 13, 2026
nikitamikhaylov added a commit that referenced this pull request Mar 13, 2026
Backport #99339 to 26.2: Revert "Merge pull request #96194 from scanhex12/add_schema_s3_check"
@nikitamikhaylov

Copy link
Copy Markdown
Member

Reverts #96194

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

Labels

pr-backports-created Backport PRs are successfully created, it won't be processed by CI script anymore pr-must-backport-synced The `*-must-backport` labels are synced into the cloud Sync PR pr-not-for-changelog This PR should not be mentioned in the changelog pr-synced-to-cloud The PR is synced to the cloud repo v26.2-must-backport

Projects

None yet

Development

Successfully merging this pull request may close these issues.

S3 schema validation introduced in 26.2 is a breaking change

4 participants