Add a test for PRQL panics

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
This commit is contained in:
Azat Khuzhin 2024-03-04 08:47:28 +01:00 committed by Maximilian Roos
parent e257f1d455
commit dc7ea2f90a
No known key found for this signature in database
GPG Key ID: 9058CC0B4BD47C30
2 changed files with 12 additions and 0 deletions

View File

@ -0,0 +1 @@
SYNTAX_ERROR

View File

@ -0,0 +1,11 @@
#!/usr/bin/env bash
CUR_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
# shellcheck source=../shell_config.sh
. "$CUR_DIR"/../shell_config.sh
# Before [1] this causes a panic, but it will be fixed soon, so do not check
# for panic, but just for SYNTAX_ERROR.
#
# [1]: https://github.com/PRQL/prql/pull/4285
$CLICKHOUSE_CLIENT --dialect prql -q "SELECT id FROM distributed_test_table GROUP BY x -> concat(concat(materialize(toNullable(NULL)))) LIMIT 3" |& grep -o -m1 SYNTAX_ERROR