Skip to content

Logical error: 'Inconsistent AST formatting: the query: (STID: 1941-1bfa) #91974

@maxknv

Description

@maxknv

Important: This issue was automatically created and is used by CI. Do not modify the issue title. Do not remove issue labels.

CI report: AST fuzzer (amd_debug)
CIDB statistics: cidb

Test output:

Error:
Logical error: 'Inconsistent AST formatting: the query:
SELECT DISTINCT x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, *, x, x, x, x, x, x, x, x, x, x, x, x, toUInt64(1) NOT IN (1234567890, 2345678901, 3456789012, 4567890123, 5678901234, 6789012345, 78901...
cannot parse query back from SELECT DISTINCT x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, *, x, x, x, x, x, x, x, x, x, x, x, x, toUInt64(1) NOT IN (1234567890, 2345678901, 3456789012, 4567890123, ...
---

Failed query:
SELECT DISTINCT x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, *, x, x, x, x, x, x, x, x, x, x, x, x, toUInt64(1) NOT IN (1234567890, 2345678901, 3456789012, 4567890123, 5678901234, 6789012345, 78901...
---

Reproduce commands (auto-generated; may require manual adjustment):
CREATE TABLE d__fuzz_36 (`a` Array(LowCardinality(Time)), `b` Array(LowCardinality(Nullable(Float64)))) ENGINE = Distributed(test_shard_localhost, currentDatabase(), t)
CREATE TABLE d__fuzz_36 (`a` Array(LowCardinality(Time)), `b` Array(LowCardinality(Nullable(Float64)))) ENGINE = Distributed(test_shard_localhost, currentDatabase(), t)
CREATE TABLE d__fuzz_36 (`a` Nullable(Decimal(38, 28)), `b` Decimal(76, 71)) ENGINE = Distributed(test_cluster_two_shards_localhost, currentDatabase(), t)
CREATE TABLE d__fuzz_36 (`a` Nullable(Decimal(38, 28)), `b` Decimal(76, 71)) ENGINE = Distributed(test_cluster_two_shards_localhost, currentDatabase(), t)
SELECT DISTINCT x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, *, x, x, x, x, x, x, x, x, x, x, x, x, toUInt64(1) NOT IN (1234567890, 2345678901, 3456789012, 4567890123, 5678901234, 6789012345, 78901...
DROP TABLE IF EXISTS d__fuzz_36
DROP TABLE IF EXISTS round
DROP TABLE IF EXISTS remote('127.0.0.2', system, one)
---

Stack trace:
__GI___pthread_kill @ 0x00000000000969fd
raise @ 0x0000000000042476
__ieee754_lgamma_r @ 0x00000000000287f3
src/Common/Exception.cpp:54: DB::abortOnFailedAssertion(String const&, std::basic_string_view<char, std::char_traits<char>>, void* const*, unsigned long, unsigned long) @ 0x0000000015c69d3c
src/Common/Exception.cpp:87: DB::handle_error_code(String const&, std::basic_string_view<char, std::char_traits<char>>, int, bool, std::vector<void*, std::allocator<void*>> const&) @ 0x0000000015c6b18...
src/Common/Exception.cpp:138: DB::Exception::Exception(DB::Exception::MessageMasked&&, int, bool) @ 0x0000000015c6b4a5
src/Common/Exception.h:123: DB::Exception::Exception(String&&, int, String, bool) @ 0x000000000d60c494
src/Common/Exception.h:58: DB::Exception::Exception(PreformattedMessage&&, int) @ 0x000000000d60c013
src/Common/Exception.h:141: DB::Exception::Exception<String&, std::basic_string_view<char, std::char_traits<char>>&>(int, FormatStringHelperImpl<std::type_identity<String&>::type, std::type_identity<s...
src/Interpreters/executeQuery.cpp:1245: DB::executeQueryImpl(char const*, char const*, std::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum, std::unique_ptr<DB::ReadBuffer, std...
src/Interpreters/executeQuery.cpp:1967: DB::executeQuery(String const&, std::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum) @ 0x000000001c23d154
src/Server/TCPHandler.cpp:777: DB::TCPHandler::runImpl() @ 0x000000001fa3df09
src/Server/TCPHandler.cpp:2873: DB::TCPHandler::run() @ 0x000000001fa591e4
base/poco/Net/src/TCPServerConnection.cpp:40: Poco::Net::TCPServerConnection::start() @ 0x0000000025f0650e
base/poco/Net/src/TCPServerDispatcher.cpp:115: Poco::Net::TCPServerDispatcher::run() @ 0x0000000025f06b7b
base/poco/Foundation/src/ThreadPool.cpp:205: Poco::PooledThread::run() @ 0x0000000025ea707f
base/poco/Foundation/src/Thread_POSIX.cpp:341: Poco::ThreadImpl::runnableEntry(void*) @ 0x0000000025ea470f
start_thread @ 0x0000000000094ac3
__GI___clone3 @ 0x00000000001268c0

Metadata

Metadata

Labels

fuzzProblem found by one of the fuzzerstestingSpecial issue with list of bugs found by CI

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions