From 060fdb223228e17cccaf7625e7f9359d98bc85ae Mon Sep 17 00:00:00 2001 From: Alex Soffronow Pagonidis <237136924+alex-clickhouse@users.noreply.github.com> Date: Wed, 19 Aug 2026 05:26:03 +0000 Subject: [PATCH] Bump ClickHouse.Driver to 1.4.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Moves the driver pin from 1.3.0 to the final 1.4.0 release. All three project files move together — src, Tests and FunctionalTests — since a split pin produces an NU1605 downgrade error. Recorded under v0.3.1 (Unreleased) in both CHANGELOG.md and RELEASENOTES.md, per AGENTS.md's instruction to keep public docs current. The notes call out the two driver behaviour changes a consumer could notice: query responses are now zstd-compressed rather than gzip by default (decoded transparently), and reading a column from ClickHouseDataReader with no current row now throws InvalidOperationException. EF Core always positions the reader before materializing, so the latter only reaches code that uses the underlying ClickHouseConnection directly. Verified locally against driver 1.4.0 (resolved version confirmed in project.assets.json for every project, not assumed): - Restore: no NuGet warnings, no NU1605 downgrade. - Build: BUILD SUCCEEDED, 0 errors, 326 warnings with --no-incremental. 326 is this repo's pre-existing warning baseline (predominantly EF1001, inherent to implementing an EF Core provider), so the delta is zero. - EFCore.ClickHouse.Tests: 661 passed, 0 failed, 0 skipped. - EFCore.ClickHouse.FunctionalTests: 323 passed, 0 failed, 4 skipped. The 4 skips are the pre-existing NorthwindJoinQueryClickHouseTest cases. Both suites run against a real ClickHouse via Testcontainers. No source changes were required. Co-Authored-By: Claude Opus 5 --- CHANGELOG.md | 3 +++ RELEASENOTES.md | 3 +++ src/EFCore.ClickHouse/EFCore.ClickHouse.csproj | 2 +- .../EFCore.ClickHouse.FunctionalTests.csproj | 2 +- test/EFCore.ClickHouse.Tests/EFCore.ClickHouse.Tests.csproj | 2 +- 5 files changed, 9 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a4d48df..693d47e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,9 @@ v0.3.1 (Unreleased) * `Sum`/`SumAsync` over a `double` or `float` column no longer throws `InvalidCastException`. EF Core wraps a top-level aggregate so the empty case returns `0`, supplying that fallback as a boxed `Int32` carrying the `Float64`/`Float32` mapping; the literal generators now convert rather than unbox. The `Float32` read path also converts, since ClickHouse widens `sum(Float32)` to `Float64` (which the driver's `GetFloat()` refuses to downcast). ([#46](https://github.com/ClickHouse/ClickHouse.EntityFrameworkCore/issues/46)) * **SummingMergeTree with multiple sum columns**: `HasSummingMergeTreeEngine("A", "B")` now generates valid DDL (`SummingMergeTree((A, B))`). Previously it emitted a comma-separated argument list (`SummingMergeTree(A, B)`), which ClickHouse rejects with `NUMBER_OF_ARGUMENTS_DOESNT_MATCH`. Single-column and no-column usage are unaffected. +### Dependencies +* **`ClickHouse.Driver` 1.3.0 → [1.4.0](https://github.com/ClickHouse/clickhouse-cs/releases/tag/1.4.0)** across the provider and both test projects (the pins must move together or restore fails with `NU1605`). No provider code changes were required. Two driver behaviour changes are worth knowing: query responses are now compressed with **zstd** instead of gzip by default (decoded transparently, no action needed), and reading a column from `ClickHouseDataReader` with no current row now throws `InvalidOperationException` instead of returning a value. The provider's own materialization always positions the reader first, so the latter only affects code that uses the underlying `ClickHouseConnection` directly. + v0.3.0 --- ### Advanced queries diff --git a/RELEASENOTES.md b/RELEASENOTES.md index 885476a..af2af0e 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -8,6 +8,9 @@ v0.3.1 (Unreleased) * Summing a `double` or `float` column (`.SumAsync(x => x.Value)`) no longer throws `InvalidCastException`. Two ClickHouse-specific mismatches were biting: EF Core hands the float literal generator a boxed `Int32` `0` as the empty-result fallback, and ClickHouse widens `sum(Float32)` to `Float64` so the driver couldn't read it back as a `float`. Both the literal generation and the `Float32` read path now convert instead of hard-casting. ([#46](https://github.com/ClickHouse/ClickHouse.EntityFrameworkCore/issues/46)) (Thanks to @HotTotem!) * **SummingMergeTree with multiple sum columns** now produces valid DDL. Configuring more than one sum column (`HasSummingMergeTreeEngine("A", "B")`) previously emitted `SummingMergeTree(A, B)`, which ClickHouse rejects with `NUMBER_OF_ARGUMENTS_DOESNT_MATCH` — the engine takes a single optional parameter that must be a tuple of columns. Multiple columns are now wrapped in a tuple (`SummingMergeTree((A, B))`); single-column and no-column usage are unchanged. +### Dependencies +* The provider now builds against **`ClickHouse.Driver` [1.4.0](https://github.com/ClickHouse/clickhouse-cs/releases/tag/1.4.0)**, up from 1.3.0, and picks up that release's substantial read-path allocation and GC reductions for free. Upgrading needs no changes to your code or configuration. Two driver-level behaviour changes are worth being aware of: query responses now come back **zstd**-compressed rather than gzip by default — the driver decodes this for you, so it is invisible unless you were inspecting raw responses — and reading a column value from a `ClickHouseDataReader` that has no current row (before the first `Read()`, or after `Read()` has returned `false`) now throws `InvalidOperationException` rather than returning something arbitrary. EF Core always positions the reader before materializing, so that only matters if you drop down to the raw `ClickHouseConnection` yourself. + v0.3.0 --- ### Advanced queries diff --git a/src/EFCore.ClickHouse/EFCore.ClickHouse.csproj b/src/EFCore.ClickHouse/EFCore.ClickHouse.csproj index 9d36a85..f0e349d 100644 --- a/src/EFCore.ClickHouse/EFCore.ClickHouse.csproj +++ b/src/EFCore.ClickHouse/EFCore.ClickHouse.csproj @@ -26,7 +26,7 @@ - + diff --git a/test/EFCore.ClickHouse.FunctionalTests/EFCore.ClickHouse.FunctionalTests.csproj b/test/EFCore.ClickHouse.FunctionalTests/EFCore.ClickHouse.FunctionalTests.csproj index 6b2c019..6e1a118 100644 --- a/test/EFCore.ClickHouse.FunctionalTests/EFCore.ClickHouse.FunctionalTests.csproj +++ b/test/EFCore.ClickHouse.FunctionalTests/EFCore.ClickHouse.FunctionalTests.csproj @@ -9,7 +9,7 @@ - + all diff --git a/test/EFCore.ClickHouse.Tests/EFCore.ClickHouse.Tests.csproj b/test/EFCore.ClickHouse.Tests/EFCore.ClickHouse.Tests.csproj index 9f28695..fdc0d6d 100644 --- a/test/EFCore.ClickHouse.Tests/EFCore.ClickHouse.Tests.csproj +++ b/test/EFCore.ClickHouse.Tests/EFCore.ClickHouse.Tests.csproj @@ -9,7 +9,7 @@ - +