Skip to content

Logical error: 'Inconsistent AST formatting: the query: #93567

@alesapin

Description

@alesapin

Important: This issue was automatically generated and is used by CI for matching failures. DO NOT modify the body content. DO NOT remove labels.

Test name: Logical error: 'Inconsistent AST formatting: the query:
CI report: BuzzHouse (amd_debug)
CIDB statistics: cidb

Test output:

Error:
Logical error: 'Inconsistent AST formatting: the query:
CREATE DICTIONARY d152 (`c0` Nullable(Int32) DEFAULT 45 EXPRESSION ((h3GetBaseCell(`c0.null`[-4]) ILIKE '\\0_爸爸认识你很高兴认识你很高兴') AND c0, toIntervalWeek(c0), -inf, c0) AS a0 INJECTIVE, `c1` Nullable(BFloat16) DEFAULT '{"_":{"c0":{},"c0":[{"c0":"2010-06-19 07:17:19.885858177","😆":[]},"learn",{}],"1":{"叫":"-113:54:23.295623503","c0.c1":[{"c0":{}}],"_":true}}}' EXPRESSION (concat(`c1.null` + `c0.null`, c0.`Map(SimpleAggregateFunction(sumWithOverflow, Map(Enum16('\n' = 23, '-1' = -15, '😀' = 38, '1000' = 128, '11' = -13, 'c0' = 127),LowCardinality(Date32))),Array(IPv4))`), if(hasTokenOrNull(concat(`c0.null`, `c0.null`), 'TRUE'), (c0 LIKE '%%%_') = `c1.null`, COLUMNS('9')), sparseGrams(c1, bitmapAnd(CAST('-13', 'Int128'), CAST('64', 'Int'))), '1900-01-01 00:00:00') HIERARCHICAL) PRIMARY KEY c1, c0 SOURCE(NULL()) LIFETIME(MIN 30 MAX 30) LAYOUT(RANGE_HASHED(RANGE_LOOKUP_STRATEGY 'min')) RANGE(MIN c1 MAX c0)
cannot parse query back from CREATE DICTIONARY `d152` (`c0` Nullable(Int32) DEFAULT 45 EXPRESSION ((h3GetBaseCell(`c0.null`[-4]) ILIKE '\\0_\xE7\x88\xB8\xE7\x88\xB8\xE8\xAE\xA4\xE8\xAF\x86\xE4\xBD\xA0\xE5\xBE\x88\xE9\xAB\x98\xE5\x85\xB4\xE8\xAE\xA4\xE8\xAF\x86\xE4\xBD\xA0\xE5\xBE\x88\xE9\xAB\x98\xE5\x85\xB4' AND `c0`, INTERVAL (`c0`) WEEK, (-inf), `c0`) AS `a0`) INJECTIVE, `c1` Nullable(BFloat16) DEFAULT '{"_":{"c0":{},"c0":[{"c0":"2010-06-19 07:17:19.885858177","😆":[]},"learn",{}],"1":{"叫":"-113:54:23.295623503","c0.c1":[{"c0":{}}],"_":true}}}' EXPRESSION (`c1.null` + `c0.null` || `c0`.`Map(SimpleAggregateFunction(sumWithOverflow, Map(Enum16('\n' = 23, '-1' = -15, '😀' = 38, '1000' = 128, '11' = -13, 'c0' = 127),LowCardinality(Date32))),Array(IPv4))`, (hasTokenOrNull(`c0.null` || `c0.null`, 'TRUE') ? `c0` LIKE '%%%_' = `c1.null` : COLUMNS('9')), sparseGrams(`c1`, bitmapAnd(-13::Int128, 64::Int)), '1900-01-01 00:00:00') HIERARCHICAL) PRIMARY KEY (`c1`, `c0`) SOURCE(NULL()) LAYOUT(RANGE_HASHED(RANGE_LOOKUP_STRATEGY 'min')) RANGE(MIN `c1`MAX `c0`) LIFETIME(MIN 30 MAX 30);'.
---

Failed query:
CREATE DICTIONARY d152 (`c0` Nullable(Int32) DEFAULT 45 EXPRESSION ((h3GetBaseCell(`c0.null`[-4]) ILIKE '\\0_爸爸认识你很高兴认识你很高兴') AND c0, toIntervalWeek(c0), -inf, c0) AS a0 INJECTIVE, `c1` Nullable(BFloat16) DEFAULT '{"_":{"c0":{},"c0":[{"c0":"2010-06-19 07:17:19.885858177","😆":[]},"learn",{}],"1":{"叫":"-113:54:23.295623503","c0.c1":[{"c0":{}}],"_":true}}}' EXPRESSION (concat(`c1.null` + `c0.null`, c0.`Map(SimpleAggregateFunction(sumWithOverflow, Map(Enum16('\n' = 23, '-1' = -15, '😀' = 38, '1000' = 128, '11' = -13, 'c0' = 127),LowCardinality(Date32))),Array(IPv4))`), if(hasTokenOrNull(concat(`c0.null`, `c0.null`), 'TRUE'), (c0 LIKE '%%%_') = `c1.null`, COLUMNS('9')), sparseGrams(c1, bitmapAnd(CAST('-13', 'Int128'), CAST('64', 'Int'))), '1900-01-01 00:00:00') HIERARCHICAL) PRIMARY KEY c1, c0 SOURCE(NULL()) LIFETIME(MIN 30 MAX 30) LAYOUT(RANGE_HASHED(RANGE_LOOKUP_STRATEGY 'min')) RANGE(MIN c1 MAX c0)
---

Stack trace:
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) @ 0x0000000015c8153c
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&) @ 0x0000000015c8298d
src/Common/Exception.cpp:138: DB::Exception::Exception(DB::Exception::MessageMasked&&, int, bool) @ 0x0000000015c82ca5
src/Common/Exception.h:123: DB::Exception::Exception(String&&, int, String, bool) @ 0x000000000d623894
src/Common/Exception.h:58: DB::Exception::Exception(PreformattedMessage&&, int) @ 0x000000000d623413
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<std::basic_string_view<char, std::char_traits<char>>&>::type>, String&, std::basic_string_view<char, std::char_traits<char>>&) @ 0x000000001c273806
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::default_delete<DB::ReadBuffer>>&, std::shared_ptr<DB::IAST>&, std::shared_ptr<DB::ImplicitTransactionControlExecutor>, std::function<void ()>, DB::QueryResultDetails&) @ 0x000000001c26a740
src/Interpreters/executeQuery.cpp:1959: DB::executeQuery(String const&, std::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum) @ 0x000000001c260014
src/Server/TCPHandler.cpp:776: DB::TCPHandler::runImpl() @ 0x000000001fa72649
src/Server/TCPHandler.cpp:2866: DB::TCPHandler::run() @ 0x000000001fa8d724
base/poco/Net/src/TCPServerConnection.cpp:40: Poco::Net::TCPServerConnection::start() @ 0x0000000025f5764e
base/poco/Net/src/TCPServerDispatcher.cpp:115: Poco::Net::TCPServerDispatcher::run() @ 0x0000000025f57cbb
base/poco/Foundation/src/ThreadPool.cpp:205: Poco::PooledThread::run() @ 0x0000000025ef81bf
base/poco/Foundation/src/Thread_POSIX.cpp:341: Poco::ThreadImpl::runnableEntry(void*) @ 0x0000000025ef584f
start_thread @ 0x0000000000094ac3
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