fix: Comet should not fail on negative limit parameter#288
Merged
viirya merged 2 commits intoapache:mainfrom Apr 19, 2024
Merged
fix: Comet should not fail on negative limit parameter#288viirya merged 2 commits intoapache:mainfrom
viirya merged 2 commits intoapache:mainfrom
Conversation
Member
Author
sunchao
approved these changes
Apr 18, 2024
viirya
commented
Apr 18, 2024
Comment on lines
+63
to
+69
| test("offset") { | ||
| assume(isSpark34Plus, "Dataset.offset is not available before Spark 3.4") | ||
| withSQLConf(CometConf.COMET_COLUMNAR_SHUFFLE_ENABLED.key -> "true") { | ||
| checkSparkAnswer(testData.offset(90)) | ||
| checkSparkAnswer(arrayData.toDF().offset(99)) | ||
| checkSparkAnswer(mapData.toDF().offset(99)) | ||
| } |
Member
Author
There was a problem hiding this comment.
Hmm, Dataset.offset is a 3.4+ API. isSpark34Plus cannot make this test buildable with 3.2/3.3. 🤔
viirya
commented
Apr 19, 2024
Comment on lines
+44
to
+51
| // Dataset.offset API is not available before Spark 3.4 | ||
| test("offset") { | ||
| withSQLConf(CometConf.COMET_COLUMNAR_SHUFFLE_ENABLED.key -> "true") { | ||
| checkSparkAnswer(testData.offset(90)) | ||
| checkSparkAnswer(arrayData.toDF().offset(99)) | ||
| checkSparkAnswer(mapData.toDF().offset(99)) | ||
| } | ||
| } |
Member
Author
There was a problem hiding this comment.
Because Dataset.offset API is only available on Spark 3.4+. I cannot have this test in CometExecSuite which will be built in Spark 3.2 and 3.3. So I move it to a 3.4 specific test suite.
advancedxy
approved these changes
Apr 19, 2024
Comment on lines
+35
to
+36
| override protected def test(testName: String, testTags: Tag*)(testFun: => Any)(implicit | ||
| pos: Position): Unit = { |
Contributor
There was a problem hiding this comment.
Nit: the indentation looks weird.
Member
Author
|
Merged. Thanks. |
himadripal
pushed a commit
to himadripal/datafusion-comet
that referenced
this pull request
Sep 7, 2024
* fix: Comet should not fail on negative limit parameter * Move test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Which issue does this PR close?
Closes #287.
Rationale for this change
What changes are included in this PR?
How are these changes tested?