You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@datafusion.apache.org by "andygrove (via GitHub)" <gi...@apache.org> on 2025/06/05 14:08:42 UTC
[PR] minor: Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator` [datafusion-comet]
andygrove opened a new pull request, #1851:
URL: https://github.com/apache/datafusion-comet/pull/1851
## Which issue does this PR close?
<!--
We generally require a GitHub issue to be filed for all bug fixes and enhancements and this helps us generate change logs for our releases. You can link an issue to this PR using the GitHub syntax. For example `Closes #123` indicates that this PR will close issue #123.
-->
N/A
## Rationale for this change
<!--
Why are you proposing this change? If this is already explained clearly in the issue then this section is not needed.
Explaining clearly why changes are proposed helps reviewers understand your changes and offer better suggestions for fixes.
-->
Improve testing and help prevent regressions
## What changes are included in this PR?
<!--
There is no need to duplicate the description in the issue here but it is sometimes worth providing a summary of the individual changes in this PR.
-->
Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator`
## How are these changes tested?
<!--
We typically require tests for all PRs in order to:
1. Prevent the code from being accidentally broken by subsequent changes
2. Serve as another way to document the expected behavior of the code
If tests are not included in your PR, please explain why (for example, are they covered by existing tests)?
-->
Existing tests
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] minor: Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator` [datafusion-comet]
Posted by "andygrove (via GitHub)" <gi...@apache.org>.
andygrove commented on PR #1851:
URL: https://github.com/apache/datafusion-comet/pull/1851#issuecomment-2944836969
> oh yeah, here we go! lgtm thanks @andygrove
Thanks for the review @comphead. This was partly inspired by our conversation yesterday.
We typically use `checkSparkAnswer` when we expect part of the plan to fall back, but we should be adding assertions to check that the expected operators fall back. I guess we can continue improving the tests over time.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] minor: Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator` [datafusion-comet]
Posted by "andygrove (via GitHub)" <gi...@apache.org>.
andygrove merged PR #1851:
URL: https://github.com/apache/datafusion-comet/pull/1851
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] minor: Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator` [datafusion-comet]
Posted by "comphead (via GitHub)" <gi...@apache.org>.
comphead commented on code in PR #1851:
URL: https://github.com/apache/datafusion-comet/pull/1851#discussion_r2129022559
##########
spark/src/test/scala/org/apache/comet/CometExpressionSuite.scala:
##########
@@ -1394,10 +1394,10 @@ class CometExpressionSuite extends CometTestBase with AdaptiveSparkPlanHelper {
checkSparkAnswerAndOperator(
s"select round(cast(${n} as decimal(20, 0)), ${s}) FROM tbl")
}
- // checkSparkAnswer(s"select round(double('infinity'), ${s}) FROM tbl")
- // checkSparkAnswer(s"select round(double('-infinity'), ${s}) FROM tbl")
- // checkSparkAnswer(s"select round(double('NaN'), ${s}) FROM tbl")
- // checkSparkAnswer(
+ // checkSparkAnswerAndOperator(s"select round(double('infinity'), ${s}) FROM tbl")
Review Comment:
its still not fixed?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] minor: Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator` [datafusion-comet]
Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #1851:
URL: https://github.com/apache/datafusion-comet/pull/1851#issuecomment-2944850645
## [Codecov](https://app.codecov.io/gh/apache/datafusion-comet/pull/1851?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
All modified and coverable lines are covered by tests :white_check_mark:
> Project coverage is 32.20%. Comparing base [(`f09f8af`)](https://app.codecov.io/gh/apache/datafusion-comet/commit/f09f8af64c6599255e116a376f4f008f2fd63b43?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) to head [(`6909d27`)](https://app.codecov.io/gh/apache/datafusion-comet/commit/6909d272894f7b3e437115de04000692c075da05?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
> Report is 243 commits behind head on main.
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## main #1851 +/- ##
=============================================
- Coverage 56.12% 32.20% -23.92%
+ Complexity 976 651 -325
=============================================
Files 119 130 +11
Lines 11743 12655 +912
Branches 2251 2357 +106
=============================================
- Hits 6591 4076 -2515
- Misses 4012 7787 +3775
+ Partials 1140 792 -348
```
</details>
[:umbrella: View full report in Codecov by Sentry](https://app.codecov.io/gh/apache/datafusion-comet/pull/1851?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
</details>
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] minor: Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator` [datafusion-comet]
Posted by "andygrove (via GitHub)" <gi...@apache.org>.
andygrove commented on code in PR #1851:
URL: https://github.com/apache/datafusion-comet/pull/1851#discussion_r2128955528
##########
spark/src/test/scala/org/apache/comet/CometArrayExpressionSuite.scala:
##########
@@ -399,12 +399,7 @@ class CometArrayExpressionSuite extends CometTestBase with AdaptiveSparkPlanHelp
sql(s"SELECT array($fieldName, $fieldName) as a, array($fieldName) as b FROM t1")
.createOrReplaceTempView("t2")
val df = sql("SELECT array_except(a, b) FROM t2")
- field.dataType match {
- case _: StructType =>
- // skip due to https://github.com/apache/datafusion-comet/issues/1314
Review Comment:
This issue is now fixed
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] minor: Replace many instances of `checkSparkAnswer` with `checkSparkAnswerAndOperator` [datafusion-comet]
Posted by "andygrove (via GitHub)" <gi...@apache.org>.
andygrove commented on code in PR #1851:
URL: https://github.com/apache/datafusion-comet/pull/1851#discussion_r2129233751
##########
spark/src/test/scala/org/apache/comet/CometExpressionSuite.scala:
##########
@@ -1394,10 +1394,10 @@ class CometExpressionSuite extends CometTestBase with AdaptiveSparkPlanHelper {
checkSparkAnswerAndOperator(
s"select round(cast(${n} as decimal(20, 0)), ${s}) FROM tbl")
}
- // checkSparkAnswer(s"select round(double('infinity'), ${s}) FROM tbl")
- // checkSparkAnswer(s"select round(double('-infinity'), ${s}) FROM tbl")
- // checkSparkAnswer(s"select round(double('NaN'), ${s}) FROM tbl")
- // checkSparkAnswer(
+ // checkSparkAnswerAndOperator(s"select round(double('infinity'), ${s}) FROM tbl")
Review Comment:
I didn't look into this since it was commented out. I actually reverted this change now.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org