```sql 
SELECT greatCircleAngle(1048575, 257, -9223372036854775808, 1048576) - NULL, bar(7, -inf, 1024)
```
https://clickhouse-test-reports.s3.yandex.net/21889/5de2b8512f4260964413448e8099c6ff5cc23881/fuzzer_ubsan/report.html#fail1
```
2021.03.23 04:33:11.673801 [ 176 ] {a0a4476b-33dd-419b-bbc3-3d2cc08b3ea8} <Debug> executeQuery: (from [::1]:39990, using production parser) SELECT greatCircleAngle(1048575, 257, -9223372036854775808, 1048576) - NULL, bar(7, -inf, 1024)
../src/Common/UnicodeBar.cpp:31:16: runtime error: -nan is outside the range of representable values of type 'unsigned long'
    #0 0xea2b1a9 in UnicodeBar::getWidthInBytes(double) obj-x86_64-linux-gnu/../src/Common/UnicodeBar.cpp:31:16
    #1 0x16c022dd in DB::(anonymous namespace)::FunctionBar::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x16c022dd)
    #2 0x12542aa4 in DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12542aa4)
    #3 0x12547e86 in DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const (/workspace/clickhouse+0x12547e86)
    #4 0x12fee2aa in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fee2aa)
    #5 0x12fed904 in DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fed904)
    #6 0x12fee134 in DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fee134)
    #7 0x12fef2ad in DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const (/workspace/clickhouse+0x12fef2ad)
    #8 0x1a0bfff5 in DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node const*, std::__1::allocator<DB::ActionsDAG::Node const*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsDAG.cpp:168:35
    #9 0x1a5f1d43 in DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:569:51
    #10 0x1a603f62 in DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:164:27
    #11 0x1a5fd0ad in DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:1049:14
    #12 0x1a60002f in DB::ActionsMatcher::visit(DB::ASTExpressionList&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp
    #13 0x1a5d6521 in DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:34:13
    #14 0x1a5c343f in DB::ExpressionAnalyzer::getRootActions(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:406:48
    #15 0x1a5cc227 in DB::SelectQueryExpressionAnalyzer::appendSelect(DB::ExpressionActionsChain&, bool) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:1119:5
    #16 0x1a5d0862 in DB::ExpressionAnalysisResult::ExpressionAnalysisResult(DB::SelectQueryExpressionAnalyzer&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, bool, bool, bool, std::__1::shared_ptr<DB::FilterDAGInfo> const&, DB::Block const&) obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:1517:24
    #17 0x1a33c834 in DB::InterpreterSelectQuery::getSampleBlockImpl() obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:596:23
    #18 0x1a33384f in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&)::$_2::operator()(bool) const obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:475:25
    #19 0x1a32e458 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:478:5
    #20 0x1a32bfc9 in DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:160:7
    #21 0x1a8603a7 in std::__1::__unique_if<DB::InterpreterSelectQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectQuery, std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&>(std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
    #22 0x1a85dd23 in DB::InterpreterSelectWithUnionQuery::buildCurrentChildInterpreter(std::__1::shared_ptr<DB::IAST> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:211:16
    #23 0x1a85c259 in DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:133:13
    #24 0x1a2c9de5 in std::__1::__unique_if<DB::InterpreterSelectWithUnionQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectWithUnionQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068:32
    #25 0x1a2c893a in DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) obj-x86_64-linux-gnu/../src/Interpreters/InterpreterFactory.cpp:110:16
    #26 0x1aaa1c89 in DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:520:28
    #27 0x1aaa0ad4 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:908:30
    #28 0x1b531d0a in DB::TCPHandler::runImpl() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:289:24
    #29 0x1b54ba9c in DB::TCPHandler::run() obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:1520:9
    #30 0x1c47aa0b in Poco::Net::TCPServerConnection::start() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerConnection.cpp:43:3
    #31 0x1c47ae62 in Poco::Net::TCPServerDispatcher::run() obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerDispatcher.cpp:113:19
    #32 0x1c5584a9 in Poco::PooledThread::run() obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/ThreadPool.cpp:199:14
    #33 0x1c5562ab in Poco::ThreadImpl::runnableEntry(void*) obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345:27
    #34 0x7fb758506608 in start_thread /build/glibc-eX1tMB/glibc-2.31/nptl/pthread_create.c:477:8
    #35 0x7fb75842d292 in clone /build/glibc-eX1tMB/glibc-2.31/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:95

SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior ../src/Common/UnicodeBar.cpp:31:16 in 
2021.03.23 04:33:12.829860 [ 42 ] {} <Trace> BaseDaemon: Received signal -3
2021.03.23 04:33:12.830531 [ 178 ] {} <Fatal> BaseDaemon: ########################################
2021.03.23 04:33:12.830693 [ 178 ] {} <Fatal> BaseDaemon: (version 21.4.1.6316, build id: AEECA1341A9DFB8420DC6FBFE9D99C901B50D217) (from thread 176) (query_id: a0a4476b-33dd-419b-bbc3-3d2cc08b3ea8) Received signal Unknown signal (-3)
2021.03.23 04:33:12.830733 [ 178 ] {} <Fatal> BaseDaemon: Sanitizer trap.
2021.03.23 04:33:12.830822 [ 178 ] {} <Fatal> BaseDaemon: Stack trace: 0xe8ff0b5 0xeb2e4d6 0xe8c2c16 0xe8d06af 0xea2b1aa 0x16c022de 0x12542aa5 0x12547e87 0x12fee2ab 0x12fed905 0x12fee135 0x12fef2ae 0x1a0bfff6 0x1a5f1d44 0x1a603f63 0x1a5fd0ae 0x1a600030 0x1a5d6522 0x1a5c3440 0x1a5cc228 0x1a5d0863 0x1a33c835 0x1a333850 0x1a32e459 0x1a32bfca 0x1a8603a8 0x1a85dd24 0x1a85c25a 0x1a2c9de6 0x1a2c893b 0x1aaa1c8a 0x1aaa0ad5
2021.03.23 04:33:12.847614 [ 178 ] {} <Fatal> BaseDaemon: 0.1. inlined from ./obj-x86_64-linux-gnu/../src/Common/StackTrace.cpp:298: StackTrace::tryCapture()
2021.03.23 04:33:12.847643 [ 178 ] {} <Fatal> BaseDaemon: 0. ../src/Common/StackTrace.cpp:259: StackTrace::StackTrace() @ 0xe8ff0b5 in /workspace/clickhouse
2021.03.23 04:33:12.901394 [ 178 ] {} <Fatal> BaseDaemon: 1. ./obj-x86_64-linux-gnu/../base/daemon/BaseDaemon.cpp:381: sanitizerDeathCallback() @ 0xeb2e4d6 in /workspace/clickhouse
2021.03.23 04:33:13.705240 [ 178 ] {} <Fatal> BaseDaemon: 2. __sanitizer::Die() @ 0xe8c2c16 in /workspace/clickhouse
2021.03.23 04:33:14.503858 [ 178 ] {} <Fatal> BaseDaemon: 3. ? @ 0xe8d06af in /workspace/clickhouse
2021.03.23 04:33:14.506068 [ 178 ] {} <Fatal> BaseDaemon: 4. ./obj-x86_64-linux-gnu/../src/Common/UnicodeBar.cpp:31: ? @ 0xea2b1aa in /workspace/clickhouse
2021.03.23 04:33:15.302761 [ 178 ] {} <Fatal> BaseDaemon: 5. DB::(anonymous namespace)::FunctionBar::executeImpl(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x16c022de in /workspace/clickhouse
2021.03.23 04:33:15.843882 [ 44 ] {} <Trace> NuKeeperTCPHandler: Received heartbeat for session #1
2021.03.23 04:33:16.098229 [ 178 ] {} <Fatal> BaseDaemon: 6. DB::IFunction::executeImplDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x12542aa5 in /workspace/clickhouse
2021.03.23 04:33:16.417730 [ 88 ] {} <Trace> SystemLog (system.query_thread_log): Flushing system log, 1314 entries to flush
2021.03.23 04:33:16.425256 [ 88 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:16.428249 [ 88 ] {} <Trace> system.query_thread_log (3dc6c240-e593-49ec-b12d-e3c70aa8e1e3): Renaming temporary part tmp_insert_202103_222_222_0 to 202103_222_222_0.
2021.03.23 04:33:16.428465 [ 88 ] {} <Trace> SystemLog (system.query_thread_log): Flushed system log
2021.03.23 04:33:16.894261 [ 178 ] {} <Fatal> BaseDaemon: 7. DB::DefaultExecutable::executeDryRun(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long) const @ 0x12547e87 in /workspace/clickhouse
2021.03.23 04:33:17.595408 [ 93 ] {} <Trace> SystemLog (system.metric_log): Flushing system log, 7 entries to flush
2021.03.23 04:33:17.604777 [ 93 ] {} <Debug> DiskLocal: Reserving 1.00 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:17.609336 [ 93 ] {} <Trace> system.metric_log (6cbecbb7-4e82-48e9-9799-208203477dcf): Renaming temporary part tmp_insert_202103_263_263_0 to 202103_263_263_0.
2021.03.23 04:33:17.610094 [ 93 ] {} <Trace> SystemLog (system.metric_log): Flushed system log
2021.03.23 04:33:17.690700 [ 178 ] {} <Fatal> BaseDaemon: 8. DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fee2ab in /workspace/clickhouse
2021.03.23 04:33:17.822008 [ 92 ] {} <Debug> DiskLocal: Reserving 2.69 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:17.827337 [ 92 ] {} <Trace> system.text_log (8f0a0548-b276-4e1a-b399-dd7e75d8f268): Renaming temporary part tmp_insert_202103_263_263_0 to 202103_263_263_0.
2021.03.23 04:33:18.359970 [ 87 ] {} <Trace> SystemLog (system.query_log): Flushing system log, 430 entries to flush
2021.03.23 04:33:18.374503 [ 87 ] {} <Debug> DiskLocal: Reserving 1.37 MiB on disk `default`, having unreserved 2.20 TiB.
2021.03.23 04:33:18.378780 [ 87 ] {} <Trace> system.query_log (30207345-07ac-4852-a5d9-b5d4e3444ad9): Renaming temporary part tmp_insert_202103_229_229_0 to 202103_229_229_0.
2021.03.23 04:33:18.379110 [ 87 ] {} <Trace> SystemLog (system.query_log): Flushed system log
2021.03.23 04:33:18.489176 [ 178 ] {} <Fatal> BaseDaemon: 9. DB::ExecutableFunctionAdaptor::defaultImplementationForConstantArguments(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fed905 in /workspace/clickhouse
2021.03.23 04:33:19.288532 [ 178 ] {} <Fatal> BaseDaemon: 10. DB::ExecutableFunctionAdaptor::executeWithoutLowCardinalityColumns(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fee135 in /workspace/clickhouse
2021.03.23 04:33:20.092411 [ 178 ] {} <Fatal> BaseDaemon: 11. DB::ExecutableFunctionAdaptor::execute(std::__1::vector<DB::ColumnWithTypeAndName, std::__1::allocator<DB::ColumnWithTypeAndName> > const&, std::__1::shared_ptr<DB::IDataType const> const&, unsigned long, bool) const @ 0x12fef2ae in /workspace/clickhouse
2021.03.23 04:33:20.254301 [ 178 ] {} <Fatal> BaseDaemon: 12.1. inlined from ./obj-x86_64-linux-gnu/../contrib/boost/boost/smart_ptr/intrusive_ptr.hpp:194: boost::intrusive_ptr<DB::IColumn const>::operator*() const
2021.03.23 04:33:20.254356 [ 178 ] {} <Fatal> BaseDaemon: 12. ../src/Interpreters/ActionsDAG.cpp:171: DB::ActionsDAG::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<DB::ActionsDAG::Node const*, std::__1::allocator<DB::ActionsDAG::Node const*> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) @ 0x1a0bfff6 in /workspace/clickhouse
2021.03.23 04:33:20.341535 [ 178 ] {} <Fatal> BaseDaemon: 13. ./obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:0: DB::ScopeStack::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) @ 0x1a5f1d44 in /workspace/clickhouse
2021.03.23 04:33:20.436159 [ 178 ] {} <Fatal> BaseDaemon: 14.1. inlined from ./obj-x86_64-linux-gnu/../contrib/libcxx/include/string:1444: std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >::__is_long() const
2021.03.23 04:33:20.436186 [ 178 ] {} <Fatal> BaseDaemon: 14.2. inlined from ../contrib/libcxx/include/string:2218: ~basic_string
2021.03.23 04:33:20.436225 [ 178 ] {} <Fatal> BaseDaemon: 14. ../src/Interpreters/ActionsVisitor.h:164: DB::ActionsMatcher::Data::addFunction(std::__1::shared_ptr<DB::IFunctionOverloadResolver> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >) @ 0x1a603f63 in /workspace/clickhouse
2021.03.23 04:33:20.524902 [ 178 ] {} <Fatal> BaseDaemon: 15.1. inlined from ./obj-x86_64-linux-gnu/../contrib/libcxx/include/string:1444: std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >::__is_long() const
2021.03.23 04:33:20.524928 [ 178 ] {} <Fatal> BaseDaemon: 15.2. inlined from ../contrib/libcxx/include/string:2218: ~basic_string
2021.03.23 04:33:20.524969 [ 178 ] {} <Fatal> BaseDaemon: 15. ../src/Interpreters/ActionsVisitor.cpp:1049: DB::ActionsMatcher::visit(DB::ASTFunction const&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) @ 0x1a5fd0ae in /workspace/clickhouse
2021.03.23 04:33:20.617513 [ 178 ] {} <Fatal> BaseDaemon: 16. ./obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.cpp:0: DB::ActionsMatcher::visit(DB::ASTExpressionList&, std::__1::shared_ptr<DB::IAST> const&, DB::ActionsMatcher::Data&) @ 0x1a600030 in /workspace/clickhouse
2021.03.23 04:33:20.720126 [ 178 ] {} <Fatal> BaseDaemon: 17. ./obj-x86_64-linux-gnu/../src/Interpreters/InDepthNodeVisitor.h:43: DB::InDepthNodeVisitor<DB::ActionsMatcher, true, std::__1::shared_ptr<DB::IAST> const>::visit(std::__1::shared_ptr<DB::IAST> const&) @ 0x1a5d6522 in /workspace/clickhouse
2021.03.23 04:33:20.810786 [ 97 ] {} <Debug> DNSResolver: Updating DNS cache
2021.03.23 04:33:20.823959 [ 178 ] {} <Fatal> BaseDaemon: 18.1. inlined from ./obj-x86_64-linux-gnu/../src/Interpreters/ActionsVisitor.h:169: DB::ActionsMatcher::Data::getActions()
2021.03.23 04:33:20.823999 [ 178 ] {} <Fatal> BaseDaemon: 18. ../src/Interpreters/ExpressionAnalyzer.cpp:407: DB::ExpressionAnalyzer::getRootActions(std::__1::shared_ptr<DB::IAST> const&, bool, std::__1::shared_ptr<DB::ActionsDAG>&, bool) @ 0x1a5c3440 in /workspace/clickhouse
2021.03.23 04:33:20.929503 [ 97 ] {} <Information> DNSResolver: Cached hosts not found: 127.0.0.{1�2}, 127.0.�.1, 127.�.0.2, 127.0.�.2, 127.�.0.1, 127.0.0.{1�.2}, 127.0.0.�1..2}, 127.0.0.1127.0.0.1127.0.0.1127.0.0.1, �27.0.0.3, 127.0.0.1127.0.0.1127.0.0.1127.0.0.2, 127.0.0.2127.0.0.2127.0.0.2127.0.0.3, 127.0.0.1127.0.0.1127.0.0.2127.0.0.2, 127.0.0.2127.0.0.2127.0.0.3127.0.0.3, 127.0.0.2127.0.0.1, 127.0.0.1127.0.0.2127.0.0.1127.0.0.1, 127.0.0.2127.0.0.1127.0.0.1127.0.0.1, 127.0.0.1127.0.0.2127.0.0.1127.0.0.2, 127.0.0.3127.0.0.2127.0.0.2127.0.0.2, 127.0.0.3127.0.0.3, 127.0.0.1127.0.0.2127.0.0.2127.0.0.2, 127.0.0.2127.0.0.2127.0.0.1127.0.0.1, 127.0.0.2127.0.0.2127.0.0.1127.0.0.2, 127.0.0.1127.0.0.2, �27.0.0.2, 127.0.0.1127.0.0.1127.0.0.2127.0.0.1, 127.0.0.3127.0.0.2127.0.0.2127.0.0.3, 127.0.0.2127.0.0.1127.0.0.2127.0.0.1, 127.0.0.2127.0.0.2127.0.0.2127.0.0.1, 127.0.0.2127.0.0.2, 127.0.0.3127.0.0.2127.0.0.3127.0.0.2, 127.0.0.2127.0.0.3, 127.0.0.2127.0.0.2127.0.0.2127.0.0.2, 127.0.0.1127.0.0.2127.0.0.2127.0.0.1, 127.0.0.2127.0.0.1127.0.0.2127.0.0.2, 127.0.0.3127.0.0.2, 127.0.0.3127.0.0.3127.0.0.3127.0.0.2, 127.0.0.2127.0.0.2127.0.0.3127.0.0.2, 127.0.0.�, 127.0.0.2127.0.0.1127.0.0.1127.0.0.2, 127.0.0.2127.0.0.3127.0.0.2127.0.0.2, 127.0.0.2127.0.0.3127.0.0.2127.0.0.3, 127.0.0.2127.0.0.3127.0.0.3127.0.0.2, 127.0.0.2127.0.0.3127.0.0.3127.0.0.3, 127.0.0.3127.0.0.2127.0.0.3127.0.0.3, 127.0.0.3127.0.0.3127.0.0.2127.0.0.2, 127.0.0.1127.0.0.1, 127.0.0.3127.0.0.3127.0.0.3127.0.0.3, 127.0.0.3127.0.0.3127.0.0.2127.0.0.3
2021.03.23 04:33:20.929547 [ 97 ] {} <Debug> DNSResolver: Updated DNS cache
2021.03.23 04:33:20.933962 [ 178 ] {} <Fatal> BaseDaemon: 19. ./obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:0: DB::SelectQueryExpressionAnalyzer::appendSelect(DB::ExpressionActionsChain&, bool) @ 0x1a5cc228 in /workspace/clickhouse
2021.03.23 04:33:21.044311 [ 178 ] {} <Fatal> BaseDaemon: 20. ./obj-x86_64-linux-gnu/../src/Interpreters/ExpressionAnalyzer.cpp:0: DB::ExpressionAnalysisResult::ExpressionAnalysisResult(DB::SelectQueryExpressionAnalyzer&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, bool, bool, bool, std::__1::shared_ptr<DB::FilterDAGInfo> const&, DB::Block const&) @ 0x1a5d0863 in /workspace/clickhouse
2021.03.23 04:33:21.220389 [ 178 ] {} <Fatal> BaseDaemon: 21. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:596: DB::InterpreterSelectQuery::getSampleBlockImpl() @ 0x1a33c835 in /workspace/clickhouse
2021.03.23 04:33:21.395050 [ 178 ] {} <Fatal> BaseDaemon: 22. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:475: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&)::$_2::operator()(bool) const @ 0x1a333850 in /workspace/clickhouse
2021.03.23 04:33:21.563546 [ 178 ] {} <Fatal> BaseDaemon: 23. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:481: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>, std::__1::shared_ptr<DB::IStorage> const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&) @ 0x1a32e459 in /workspace/clickhouse
2021.03.23 04:33:21.731336 [ 178 ] {} <Fatal> BaseDaemon: 24. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:160: DB::InterpreterSelectQuery::InterpreterSelectQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a32bfca in /workspace/clickhouse
2021.03.23 04:33:21.804719 [ 178 ] {} <Fatal> BaseDaemon: 25. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2068: std::__1::__unique_if<DB::InterpreterSelectQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectQuery, std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&>(std::__1::shared_ptr<DB::IAST> const&, DB::Context&, DB::SelectQueryOptions&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a8603a8 in /workspace/clickhouse
2021.03.23 04:33:21.871690 [ 178 ] {} <Fatal> BaseDaemon: 26. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:211: DB::InterpreterSelectWithUnionQuery::buildCurrentChildInterpreter(std::__1::shared_ptr<DB::IAST> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a85dd24 in /workspace/clickhouse
2021.03.23 04:33:21.937672 [ 178 ] {} <Fatal> BaseDaemon: 27. ./obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:133: DB::InterpreterSelectWithUnionQuery::InterpreterSelectWithUnionQuery(std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::SelectQueryOptions const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) @ 0x1a85c25a in /workspace/clickhouse
2021.03.23 04:33:21.998919 [ 178 ] {} <Fatal> BaseDaemon: 28. ./obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:0: std::__1::__unique_if<DB::InterpreterSelectWithUnionQuery>::__unique_single std::__1::make_unique<DB::InterpreterSelectWithUnionQuery, std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&>(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) @ 0x1a2c9de6 in /workspace/clickhouse
2021.03.23 04:33:22.059268 [ 178 ] {} <Fatal> BaseDaemon: 29.1. inlined from ./obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:1649: std::__1::unique_ptr<DB::InterpreterSelectWithUnionQuery, std::__1::default_delete<DB::InterpreterSelectWithUnionQuery> >::release()
2021.03.23 04:33:22.059306 [ 178 ] {} <Fatal> BaseDaemon: 29.2. inlined from ../contrib/libcxx/include/memory:1563: unique_ptr<DB::InterpreterSelectWithUnionQuery, std::__1::default_delete<DB::InterpreterSelectWithUnionQuery>, void, void>
2021.03.23 04:33:22.059355 [ 178 ] {} <Fatal> BaseDaemon: 29. ../src/Interpreters/InterpreterFactory.cpp:110: DB::InterpreterFactory::get(std::__1::shared_ptr<DB::IAST>&, DB::Context&, DB::SelectQueryOptions const&) @ 0x1a2c893b in /workspace/clickhouse
2021.03.23 04:33:22.157200 [ 178 ] {} <Fatal> BaseDaemon: 30. ./obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:520: DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) @ 0x1aaa1c8a in /workspace/clickhouse
2021.03.23 04:33:22.259269 [ 178 ] {} <Fatal> BaseDaemon: 31. ./obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:908: DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) @ 0x1aaa0ad5 in /workspace/clickhouse
2021.03.23 04:33:22.462588 [ 178 ] {} <Fatal> BaseDaemon: Calculated checksum of the binary: 799351CC5D5B54DA933C4DA73FD28F72. There is no information about the reference checksum.
```
ColumnNumbers getArgumentsThatAreAlwaysConstant() const override { return {3}; }
    ColumnPtr executeImpl(const ColumnsWithTypeAndName & arguments, const DataTypePtr &, size_t input_rows_count) const override
    {
        
        Float64 max_width = 80; 
        if (arguments.size() == 4)
        {
            const auto & max_width_column = *arguments[3].column;
            if (!isColumnConst(max_width_column))
                throw Exception(ErrorCodes::ILLEGAL_COLUMN, "Fourth argument for function {} must be constant", getName());
            max_width = max_width_column.getFloat64(0);
        }
        if (isNaN(max_width))
            throw Exception("Argument 'max_width' must not be NaN", ErrorCodes::ILLEGAL_TYPE_OF_ARGUMENT);
        if (max_width < 1)
            throw Exception("Argument 'max_width' must be >= 1", ErrorCodes::ARGUMENT_OUT_OF_BOUND);
        if (max_width > 1000)
            throw Exception("Argument 'max_width' must be <= 1000", ErrorCodes::ARGUMENT_OUT_OF_BOUND);