Skip to content

Commit d5d2a08

Browse files
committed
fixed tests
1 parent 348c65e commit d5d2a08

File tree

4 files changed

+6
-5
lines changed

4 files changed

+6
-5
lines changed

src/Interpreters/ErrorLog.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,8 +119,8 @@ void ErrorLogElement::appendToBlock(MutableColumns & columns) const
119119

120120
std::vector<UInt64> error_trace_array;
121121
error_trace_array.reserve(error_trace.size());
122-
for (size_t i = 0; i < error_trace.size(); ++i)
123-
error_trace_array.emplace_back(reinterpret_cast<UInt64>(error_trace[i]));
122+
for (auto * ptr : error_trace)
123+
error_trace_array.emplace_back(reinterpret_cast<UInt64>(ptr));
124124

125125
columns[column_idx++]->insert(Array(error_trace_array.begin(), error_trace_array.end()));
126126

src/Interpreters/SystemLog.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
#include <Interpreters/Context.h>
1515
#include <Interpreters/CrashLog.h>
1616
#include <Interpreters/DatabaseCatalog.h>
17-
#include <Interpreters/ErrorLog.h>
1817
#include <Interpreters/FilesystemCacheLog.h>
1918
#include <Interpreters/FilesystemReadPrefetchesLog.h>
2019
#include <Interpreters/InterpreterCreateQuery.h>

tests/queries/0_stateless/02117_show_create_table_system.reference

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,9 @@ CREATE TABLE system.errors
265265
`last_error_message` String,
266266
`last_error_trace` Array(UInt64),
267267
`remote` UInt8,
268-
`query_id` String
268+
`last_error_query_id` String,
269+
`last_error_symbols` Array(LowCardinality(String)),
270+
`last_error_lines` Array(LowCardinality(String))
269271
)
270272
ENGINE = SystemErrors
271273
COMMENT 'Contains a list of all errors which have ever happened including the error code, last time and message with unsymbolized stacktrace.'

tests/queries/0_stateless/03361_system_errors_query_id.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ $CLICKHOUSE_CLIENT --query_id="$query_id" -q "select query_id" &>/dev/null
1010

1111
retry=0
1212
max_retries=30
13-
while [[ $($CLICKHOUSE_CLIENT -q "SELECT count(*) FROM system.errors WHERE query_id = '$query_id' and code = 47") -lt 1 ]]; do
13+
while [[ $($CLICKHOUSE_CLIENT -q "SELECT count(*) FROM system.errors WHERE last_error_query_id = '$query_id' and code = 47") -lt 1 ]]; do
1414
retry=$((retry+1))
1515

1616
if [ $retry -ge $max_retries ]; then

0 commit comments

Comments
 (0)