-
Notifications
You must be signed in to change notification settings - Fork 24.9k
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
[CI] LogicalPlanOptimizerTests testSimplifyComparisionArithmetics_floatDivision failing #108524
Comments
Pinging @elastic/es-analytical-engine (Team:Analytics) |
This test is originally from Here is the trace from ESQL, after the first iteration to apply
However, in
If the |
That |
Here are the difference between
|
Ah, yeah, I remember that change. Using |
Yes, the QL code seems incorrect as it doesn't actually enforce the type -- |
I only found it in ES|QL because it was getting a class cast exception trying to reconcile the blocks. I suspect since we don't have typed blocks in SQL, we never saw the type miss-match. |
The
SimplifyComparisonArithimetics
optimizer fails to optimize the expression2 / float < 4
. It seems like on the first pass through, it generates the expressionfloat * 4.0 > 2
, but then doesn't further optimize that tofloat > 0.5
. I think it detects a floating point multiplication in the second expression, which is considered an unsafe optimization.Build scan:
https://gradle-enterprise.elastic.co/s/zn7kv6lwmdrow/tests/:x-pack:plugin:esql:test/org.elasticsearch.xpack.esql.optimizer.LogicalPlanOptimizerTests/testSimplifyComparisionArithmetics_floatDivision
Reproduction line:
Applicable branches:
main
Reproduces locally?:
Yes
Failure history:
Failure dashboard for
org.elasticsearch.xpack.esql.optimizer.LogicalPlanOptimizerTests#testSimplifyComparisionArithmetics_floatDivision
Failure excerpt:
The text was updated successfully, but these errors were encountered: