> You have to provide the following information whenever possible.

**Describe what's wrong**

https://s3.amazonaws.com/clickhouse-test-reports/45106/e51123c9b0cd2a8c38cc2dc6ef1ba28be06c7e9b/stateless_tests__debug__[2/5].html

crash stack
```
115503:2023.01.19 02:39:08.645970 [ 3485 ] {d163bcac-482b-46f5-8c83-076f89b43108} <Fatal> : Logical error: 'Function multiMatchAny(materialize('Привет, World'), ['^hell', '(?i)привет', '(?i)^world']) OR 0 expects 3 arguments but has 2 after running ConvertOrLikeChain pass'.
115515:2023.01.19 02:39:08.647565 [ 5233 ] {} <Fatal> BaseDaemon: ########################################
115516:2023.01.19 02:39:08.647991 [ 5233 ] {} <Fatal> BaseDaemon: (version 22.13.1.1, build id: 048E04C589FC63BE30B8F12F63B205DFDD477558) (from thread 3485) (query_id: d163bcac-482b-46f5-8c83-076f89b43108) (query: EXPLAIN QUERY TREE run_passes=1 SELECT materialize('Привет, World') AS s WHERE (s LIKE 'hell%') OR (s ILIKE '%привет%') OR (s ILIKE 'world%') SETTINGS optimize_or_like_chain = 1, allow_experimental_analyzer = 1;) Received signal Aborted (6)
115518:2023.01.19 02:39:08.648348 [ 5233 ] {} <Fatal> BaseDaemon: 
115520:2023.01.19 02:39:08.648740 [ 5233 ] {} <Fatal> BaseDaemon: Stack trace: 0x7f8acf6f400b 0x7f8acf6d3859 0x2190163e 0x21901735 0x21901885 0x18de34ca 0x29e5a81e 0x29e56563 0x29e56137 0x29e54c96 0x29e560a2 0x29e54cb3 0x29e54ecf 0x29df7120 0x29df680b 0x2a4ef6ca 0x2a4eb4e4 0x2be9c4c6 0x2bead7a5 0x30a8aa99 0x30a8b2dc 0x30cda454 0x30cd71fa 0x30cd5fde 0x7f8acf8ab609 0x7f8acf7d0133
115521:2023.01.19 02:39:08.649139 [ 5233 ] {} <Fatal> BaseDaemon: 4. raise @ 0x7f8acf6f400b in ?
115522:2023.01.19 02:39:08.649396 [ 5233 ] {} <Fatal> BaseDaemon: 5. abort @ 0x7f8acf6d3859 in ?
115927:2023.01.19 02:39:08.796636 [ 5233 ] {} <Fatal> BaseDaemon: 6. /build/build_docker/../src/Common/Exception.cpp:41: DB::abortOnFailedAssertion(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&) @ 0x2190163e in /usr/bin/clickhouse
116380:2023.01.19 02:39:08.928221 [ 5233 ] {} <Fatal> BaseDaemon: 7. /build/build_docker/../src/Common/Exception.cpp:64: DB::handle_error_code(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, int, bool, std::__1::vector<void*, std::__1::allocator<void*>> const&) @ 0x21901735 in /usr/bin/clickhouse
116533:2023.01.19 02:39:09.021859 [ 5233 ] {} <Fatal> BaseDaemon: 8. /build/build_docker/../src/Common/Exception.cpp:78: DB::Exception::Exception(DB::Exception::MessageMasked const&, int, bool) @ 0x21901885 in /usr/bin/clickhouse
116691:2023.01.19 02:39:09.148041 [ 5233 ] {} <Fatal> BaseDaemon: 9. /build/build_docker/../src/Common/Exception.h:41: DB::Exception::Exception(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, int, bool) @ 0x18de34ca in /usr/bin/clickhouse
116797:2023.01.19 02:39:09.262123 [ 5233 ] {} <Fatal> BaseDaemon: 10. /build/build_docker/../src/Common/Exception.h:50: DB::Exception::Exception<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, unsigned long&, unsigned long, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&>(int, fmt::v8::basic_format_string<char, fmt::v8::type_identity<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>::type, fmt::v8::type_identity<unsigned long&>::type, fmt::v8::type_identity<unsigned long>::type, fmt::v8::type_identity<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&>::type>, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&&, unsigned long&, unsigned long&&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&) @ 0x29e5a81e in /usr/bin/clickhouse
116829:2023.01.19 02:39:09.360097 [ 5233 ] {} <Fatal> BaseDaemon: 11. /build/build_docker/../src/Analyzer/QueryTreePassManager.cpp:91: DB::(anonymous namespace)::ValidationChecker::visitFunction(DB::FunctionNode*) const @ 0x29e56563 in /usr/bin/clickhouse
116890:2023.01.19 02:39:09.471347 [ 5233 ] {} <Fatal> BaseDaemon: 12. /build/build_docker/../src/Analyzer/QueryTreePassManager.cpp:65: DB::(anonymous namespace)::ValidationChecker::visitImpl(std::__1::shared_ptr<DB::IQueryTreeNode>&) const @ 0x29e56137 in /usr/bin/clickhouse
116973:2023.01.19 02:39:09.564372 [ 5233 ] {} <Fatal> BaseDaemon: 13. /build/build_docker/../src/Analyzer/InDepthQueryTreeVisitor.h:59: DB::InDepthQueryTreeVisitor<DB::(anonymous namespace)::ValidationChecker, false>::visit(std::__1::shared_ptr<DB::IQueryTreeNode>&) @ 0x29e54c96 in /usr/bin/clickhouse
117041:2023.01.19 02:39:09.676569 [ 5233 ] {} <Fatal> BaseDaemon: 14. /build/build_docker/../src/Analyzer/InDepthQueryTreeVisitor.h:76: DB::InDepthQueryTreeVisitor<DB::(anonymous namespace)::ValidationChecker, false>::visitChildren(std::__1::shared_ptr<DB::IQueryTreeNode>&) @ 0x29e560a2 in /usr/bin/clickhouse
117095:2023.01.19 02:39:09.769046 [ 5233 ] {} <Fatal> BaseDaemon: 15. /build/build_docker/../src/Analyzer/InDepthQueryTreeVisitor.h:61: DB::InDepthQueryTreeVisitor<DB::(anonymous namespace)::ValidationChecker, false>::visit(std::__1::shared_ptr<DB::IQueryTreeNode>&) @ 0x29e54cb3 in /usr/bin/clickhouse
117144:2023.01.19 02:39:09.856860 [ 5233 ] {} <Fatal> BaseDaemon: 16. /build/build_docker/../src/Analyzer/QueryTreePassManager.cpp:174: DB::QueryTreePassManager::run(std::__1::shared_ptr<DB::IQueryTreeNode>, unsigned long) @ 0x29e54ecf in /usr/bin/clickhouse
117413:2023.01.19 02:39:10.097410 [ 5233 ] {} <Fatal> BaseDaemon: 17. /build/build_docker/../src/Interpreters/InterpreterExplainQuery.cpp:409: DB::InterpreterExplainQuery::executeImpl() @ 0x29df7120 in /usr/bin/clickhouse
117772:2023.01.19 02:39:10.321784 [ 5233 ] {} <Fatal> BaseDaemon: 18. /build/build_docker/../src/Interpreters/InterpreterExplainQuery.cpp:87: DB::InterpreterExplainQuery::execute() @ 0x29df680b in /usr/bin/clickhouse
117929:2023.01.19 02:39:10.587370 [ 5233 ] {} <Fatal> BaseDaemon: 19. /build/build_docker/../src/Interpreters/executeQuery.cpp:709: DB::executeQueryImpl(char const*, char const*, std::__1::shared_ptr<DB::Context>, bool, DB::QueryProcessingStage::Enum, DB::ReadBuffer*) @ 0x2a4ef6ca in /usr/bin/clickhouse
118760:2023.01.19 02:39:10.875258 [ 5233 ] {} <Fatal> BaseDaemon: 20. /build/build_docker/../src/Interpreters/executeQuery.cpp:1108: DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::Context>, bool, DB::QueryProcessingStage::Enum) @ 0x2a4eb4e4 in /usr/bin/clickhouse
118993:2023.01.19 02:39:11.166809 [ 5233 ] {} <Fatal> BaseDaemon: 21. /build/build_docker/../src/Server/TCPHandler.cpp:378: DB::TCPHandler::runImpl() @ 0x2be9c4c6 in /usr/bin/clickhouse
119416:2023.01.19 02:39:11.497499 [ 5233 ] {} <Fatal> BaseDaemon: 22. /build/build_docker/../src/Server/TCPHandler.cpp:1945: DB::TCPHandler::run() @ 0x2bead7a5 in /usr/bin/clickhouse
119497:2023.01.19 02:39:11.527666 [ 5233 ] {} <Fatal> BaseDaemon: 23. /build/build_docker/../contrib/poco/Net/src/TCPServerConnection.cpp:43: Poco::Net::TCPServerConnection::start() @ 0x30a8aa99 in /usr/bin/clickhouse
119598:2023.01.19 02:39:11.568777 [ 5233 ] {} <Fatal> BaseDaemon: 24. /build/build_docker/../contrib/poco/Net/src/TCPServerDispatcher.cpp:115: Poco::Net::TCPServerDispatcher::run() @ 0x30a8b2dc in /usr/bin/clickhouse
119622:2023.01.19 02:39:11.603897 [ 5233 ] {} <Fatal> BaseDaemon: 25. /build/build_docker/../contrib/poco/Foundation/src/ThreadPool.cpp:199: Poco::PooledThread::run() @ 0x30cda454 in /usr/bin/clickhouse
119745:2023.01.19 02:39:11.639627 [ 5233 ] {} <Fatal> BaseDaemon: 26. /build/build_docker/../contrib/poco/Foundation/src/Thread.cpp:56: Poco::(anonymous namespace)::RunnableHolder::run() @ 0x30cd71fa in /usr/bin/clickhouse
119760:2023.01.19 02:39:11.670593 [ 5233 ] {} <Fatal> BaseDaemon: 27. /build/build_docker/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345: Poco::ThreadImpl::runnableEntry(void*) @ 0x30cd5fde in /usr/bin/clickhouse
119761:2023.01.19 02:39:11.670848 [ 5233 ] {} <Fatal> BaseDaemon: 28. ? @ 0x7f8acf8ab609 in ?
119762:2023.01.19 02:39:11.671046 [ 5233 ] {} <Fatal> BaseDaemon: 29. clone @ 0x7f8acf7d0133 in ?
119763:2023.01.19 02:39:11.671202 [ 5233 ] {} <Fatal> BaseDaemon: Integrity check of the executable skipped because the reference checksum could not be read.
134992:2023.01.19 02:39:28.714967 [ 648 ] {} <Fatal> Application: Child process was terminated by signal 6.

```


throw Exception(ErrorCodes::LOGICAL_ERROR,
                    "Function {} expects {} argument to have {} type but receives {} after running {} pass",
                    function->toAST()->formatForErrorMessage(),
                    i + 1,
                    expected_argument_types[i]->getName(),
                    actual_argument_columns[i].type->getName(),
                    pass_name);
            }
        }
    }
    String pass_name;
};
#endif
}
/** ClickHouse query tree pass manager.
  *
  * TODO: Support _shard_num into shardNum() rewriting.
  * TODO: Support logical expressions optimizer.
  * TODO: Support setting convert_query_to_cnf.
  * TODO: Support setting optimize_using_constraints.
  * TODO: Support setting optimize_substitute_columns.
  * TODO: Support GROUP BY injective function elimination.
  * TODO: Support setting optimize_move_functions_out_of_any.
  * TODO: Support setting optimize_aggregators_of_group_by_keys.
  * TODO: Support setting optimize_duplicate_order_by_and_distinct.
  * TODO: Support setting optimize_monotonous_functions_in_order_by.
  * TODO: Support settings.optimize_or_like_chain.
  * TODO: Add optimizations based on function semantics. Example: SELECT * FROM test_table WHERE id != id. (id is not nullable column).
  */
QueryTreePassManager::QueryTreePassManager(ContextPtr context_) : WithContext(context_) {}