-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Nightly Join fuzzer consistent faluire 'duckdb::InternalException' values[i].type() == values[0].type() #7943
Comments
Tried to reproduce using seed on my Mac. The query plan looks the same, but it didn't fail.
|
Also tried on a linux box (devserver). Still no error. Wondering if somehow duckdb version installed in CI is different. CC: @kgpai
|
Yesterday's failure: https://github.com/facebookincubator/velox/actions/runs/7456109693/job/20287244934
|
The error happens while creating DuckDB table with data that includes an ARRAY(BOOLEAN).
|
I do not see duckdb::Value(bool) signature and wonder if we need to use duckdb::BOOLEAN(true|false) instead. |
@kgpai Krishna is adding Join Fuzzer to experimental jobs in #8319. This should allow then to experiment with this failure by running adhoc jobs from https://github.com/facebookincubator/velox/actions/workflows/experimental.yml |
Instructions to reproduce CI failures using Docker: #8371 |
DuckDB failure here comes from debug-only check. Wondering if there is any particular reason for building DuckDB in debug mode. CC: @kgpai |
The error comes from debug check in DuckDB: src/common/types/value.cpp
The check failure is caused by
duckValueAt template called with BOOLEAN, TINYINT and SMALLINT values ends up creating a value of type INTEGER. It uses duckdb::Value API which is not defined for bool, int8_t and int16_t, but defined for int32_t and other types. Hence, compiler silently casts bool, int8_t and int16_t into int32_t and calls duckdb::Value(int32_t) which returns a value of type INTEGER.
However, null values are converted using :duckdb::Value(duckdb::fromVeloxType(elements->type()))) which takes type explicitly. Hence, when there is a mix of null and non-null values of type BOOLEAN, TINYINT or SMALLINT we end up with a list of values of different types and hit the debug check in DuckDB. A fix could be to provide explicit overrides for these types:
or use a version of duckdb::Value::LIST that takes an additional 'type' parameter and casts values to that type. I verified that this option allows the join fuzzer in CI to run successfully.
|
Confirmed that Join Fuzzer job no longer fails: https://app.circleci.com/pipelines/github/facebookincubator/velox/42618/workflows/3d5dc700-8e6d-44dd-8661-a6fec12c13f8/jobs/294938 |
I believe I tracked down this issue being introduced in #6725: https://github.com/facebookincubator/velox/pull/6725/files#r1455417084 CC: @majetideepak |
@mbasmanova thanks for investigating this tricky issue. |
Description
Error Reproduction
https://github.com/facebookincubator/velox/actions/runs/7123232991/job/19395529656
Relevant logs
No response
The text was updated successfully, but these errors were encountered: