v25.12 Changelog for Cloud

### Memory and crash fixes[​](#memory-and-crash-fixes "Direct link to Memory and crash fixes")

- Fix possible crash during remote query with `ARRAY JOIN` inside `IN` and enabled `enable_lazy_columns_replication` setting. Resolves [#90361](https://github.com/ClickHouse/ClickHouse/issues/90361). [#89997](https://github.com/ClickHouse/ClickHouse/pull/89997) ([Pavel Kruglov](https://github.com/Avogar)).
- Fixed a crash during the clean server shutdown due to wrong destruction order. Resolves [#82420](https://github.com/ClickHouse/ClickHouse/issues/82420). [#90076](https://github.com/ClickHouse/ClickHouse/pull/90076) ([Nikita Mikhaylov](https://github.com/nikitamikhaylov)).
- Fix a crash in case if a state of an aggregate function contains a serialized value of a column of LowCardinality(String). [#89550](https://github.com/ClickHouse/ClickHouse/pull/89550) ([Pavel Kruglov](https://github.com/Avogar)).
- Fix crash in StorageDistributed when parsing malformed shard directory names. [#90243](https://github.com/ClickHouse/ClickHouse/pull/90243) ([Aleksandr Musorin](https://github.com/AVMusorin)).
- Fixed spurious memory limit errors when userspace page cache is enabled. [#91361](https://github.com/ClickHouse/ClickHouse/pull/91361) ([Michael Kolupaev](https://github.com/al13n321)).
- Fix possible crash in aggregate functions after `MEMORY_LIMIT_EXCEEDED`. [#92390](https://github.com/ClickHouse/ClickHouse/pull/92390) ([Azat Khuzhin](https://github.com/azat)).
- Improved memory tracking in hash joins result generation. [#89560](https://github.com/ClickHouse/ClickHouse/pull/89560) ([Azat Khuzhin](https://github.com/azat)).

### Security and access fixes[​](#security-and-access-fixes "Direct link to Security and access fixes")

- Fix `ACCESS_ENTITY_NOT_FOUND` error when trying to execute clusterAllReplicas from a user with a non-existing role. Resolves [#87670](https://github.com/ClickHouse/ClickHouse/issues/87670). [#89068](https://github.com/ClickHouse/ClickHouse/pull/89068) ([pufit](https://github.com/pufit)).
- Fix access validation for `ALTER UPDATE` queries when a `remote` table function is used with `localhost` as a target host. [#90761](https://github.com/ClickHouse/ClickHouse/pull/90761) ([pufit](https://github.com/pufit)).
- Fix wildcard grants check for partial revoke. [#90922](https://github.com/ClickHouse/ClickHouse/pull/90922) ([pufit](https://github.com/pufit)).
- Fix handling global grants with wildcard revokes. [#90928](https://github.com/ClickHouse/ClickHouse/pull/90928) ([pufit](https://github.com/pufit)).

### Replicated database fixes[​](#replicated-database-fixes "Direct link to Replicated database fixes")

- After recovering, a Replicated database replica might get stuck for a long time printing messages like `Failed to marked query-0004647339 as finished`, it's fixed. [#88671](https://github.com/ClickHouse/ClickHouse/pull/88671) ([Alexander Tokmakov](https://github.com/tavplubix)).
- Fix use-after-free in Distributed due to race between shutdown and background `INSERT`s. Resolves [#88640](https://github.com/ClickHouse/ClickHouse/issues/88640). [#89136](https://github.com/ClickHouse/ClickHouse/pull/89136) ([Azat Khuzhin](https://github.com/azat)).
- Refreshable materialized view: fixed rare server crash if source table was fully dropped during a refresh. [#89203](https://github.com/ClickHouse/ClickHouse/pull/89203) ([Michael Kolupaev](https://github.com/al13n321)).

### Keeper fixes[​](#keeper-fixes "Direct link to Keeper fixes")

- Fix reading of changelogs during Keeper startup in cases a changelog was not renamed properly during rotation. [#89496](https://github.com/ClickHouse/ClickHouse/pull/89496) ([Antonio Andelic](https://github.com/antonio2368)).

### Other notable fixes[​](#other-notable-fixes "Direct link to Other notable fixes")

- Fixed performance degradation in analysis of skipping indexes. [#89004](https://github.com/ClickHouse/ClickHouse/pull/89004) ([Anton Popov](https://github.com/CurtizJ)).
- Fix hive partitioning incompatibility preventing smooth upgrade in 25.8. [#90202](https://github.com/ClickHouse/ClickHouse/pull/90202) ([Kseniia Sumarokova](https://github.com/kssenii)).
- Fix infinite `nan`/`inf` `WITH FILL` query. Resolves [#69261](https://github.com/ClickHouse/ClickHouse/issues/69261). [#90255](https://github.com/ClickHouse/ClickHouse/pull/90255) ([Konstantin Bogdanov](https://github.com/thevar1able)).
- Time and Time64 now should respect timezones correctly while converting from DateTime and DateTime64. Closes [#89896](https://github.com/ClickHouse/ClickHouse/issues/89896). [#90310](https://github.com/ClickHouse/ClickHouse/pull/90310) ([Yarik Briukhovetskyi](https://github.com/yariks5s)).
- Fixed possible incorrect query results after lightweight updates in `SELECT` queries with the enabled query condition cache. Fixes [#90176](https://github.com/ClickHouse/ClickHouse/issues/90176). [#90204](https://github.com/ClickHouse/ClickHouse/pull/90204) ([Anton Popov](https://github.com/CurtizJ)).
- Fix compatibility of in-memory serialization of String aggregation state. [#90880](https://github.com/ClickHouse/ClickHouse/pull/90880) ([Antonio Andelic](https://github.com/antonio2368)).
- Fixes `SummingMergeTree` aggregation for `Nested` `LowCardinality` columns. [#90927](https://github.com/ClickHouse/ClickHouse/pull/90927) ([Ivan Babrou](https://github.com/bobrik)).
- Fix `system.view_refreshes` failing with error `No macro 'replica' in config`. [#92203](https://github.com/ClickHouse/ClickHouse/pull/92203) ([Michael Kolupaev](https://github.com/al13n321)).
- Fix replication of an alter indirectly adding a column to MV with Shared Catalog. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix failed MV commit hanging the Shared Catalog state application. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix setting constraints check in `ALTER`s on secondary replicas with Shared Catalog. ([Nikolay Degterinsky](https://github.com/evillique)).
- Keep database comment on SharedCatalog migration. ([Alexander Tokmakov](https://github.com/tavplubix)).
- Fix Materialized Views being replaced on secondary replicas in Shared Catalog. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix system.distributed\_cache\_usage counters. ([Kseniia Sumarokova](https://github.com/kssenii)).
- Fix the stuck DROP of a table that failed to create with an `ILLEGAL_COLUMN` exception in Shared Catalog. ([Nikolay Degterinsky](https://github.com/evillique)).
- Disable `CREATE OR REPLACE` for SharedSet/SharedJoin in Replicated databases. ([Tuan Pham Anh](https://github.com/tuanpach)).
- Fix `UNFINISHED` exceptions in RMV refreshes with the Shared database. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix crash with `TABLE_ALREADY_EXISTS` in Shared databases. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix migration of tables with broken create queries in the Shared Catalog. ([Nikolay Degterinsky](https://github.com/evillique)).
- Always use virtual parts from memory in `getStatus`. ([Mikhail Artemenko](https://github.com/Michicosun)).
- Add retries to the Shared catalog state application during startup. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix for `DROP DATABASE` being stuck after exception during table creation. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix logical error in distributed cache. ([Kseniia Sumarokova](https://github.com/kssenii)).
- Fix distributed cache incorrect error. ([Kseniia Sumarokova](https://github.com/kssenii)).
- Fix `LOGICAL_ERROR` in ~TemporaryLockForUUIDDirectory in Shared Catalog. ([Nikolay Degterinsky](https://github.com/evillique)).
- Fix metadata cache returning incorrect dependencies after renaming a database. ([Nikolay Degterinsky](https://github.com/evillique)).
- Shared Catalog: Fix a case of DROP of big tables on secondary replicas. ([Raúl Marín](https://github.com/Algunenano)).
- Distributed cache fix logical error in `processWriteRequest`. ([Kseniia Sumarokova](https://github.com/kssenii)).
- Remove checks for MV `ALTER`s on secondary replicas. ([Nikolay Degterinsky](https://github.com/evillique)).