-
Notifications
You must be signed in to change notification settings - Fork 28.4k
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
[SPARK-49579][SQL][TESTS] Rename errorClass
to condition
in checkError()
#48027
Closed
Conversation
This file contains 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
github-actions
bot
added
SQL
ML
STRUCTURED STREAMING
WEB UI
CORE
PYTHON
AVRO
CONNECT
PROTOBUF
labels
Sep 8, 2024
MaxGekk
changed the title
[WIP][TESTS] Rename
[SPARK-49579][SQL][TESTS] Rename Sep 10, 2024
errorClass
to condition
in checkError()
errorClass
to condition
in checkError()
@srielau @panbingkun @nchammas @cloud-fan Could you review the PR, please. |
cloud-fan
approved these changes
Sep 10, 2024
Merging to master. Thank you, @cloud-fan for review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi, @MaxGekk and @cloud-fan . Unfortunately, this seems to break master
branch compilation for some reasons. Could you double-check?
[error] /home/runner/work/spark/spark/core/src/test/scala/org/apache/spark/SparkThrowableSuite.scala:509:5: overloaded method checkError with alternatives:
[error] (exception: org.apache.spark.SparkThrowable,condition: String,sqlState: Option[String],parameters: Map[String,String],context: SparkThrowableSuite.this.ExpectedContext)Unit <and>
[error] (exception: org.apache.spark.SparkThrowable,condition: String,sqlState: String,context: SparkThrowableSuite.this.ExpectedContext)Unit <and>
[error] (exception: org.apache.spark.SparkThrowable,condition: String,parameters: Map[String,String],context: SparkThrowableSuite.this.ExpectedContext)Unit <and>
[error] (exception: org.apache.spark.SparkThrowable,condition: String,sqlState: String,parameters: Map[String,String],context: SparkThrowableSuite.this.ExpectedContext)Unit <and>
[error] (exception: org.apache.spark.SparkThrowable,condition: String,sqlState: String,parameters: Map[String,String])Unit <and>
[error] (exception: org.apache.spark.SparkThrowable,condition: String,sqlState: Option[String],parameters: Map[String,String],matchPVals: Boolean,queryContext: Array[SparkThrowableSuite.this.ExpectedContext])Unit
[error] [which have no such parameter errorClass] cannot be applied to (exception: org.apache.spark.SparkException, errorClass: String, parameters: scala.collection.immutable.Map[String,String])
[error] checkError(
[error] ^
MaxGekk
added a commit
that referenced
this pull request
Sep 10, 2024
…Class` in `SparkThrowableSuite` and in `DateTimeFormatterHelperSuite` ### What changes were proposed in this pull request? In the PR, I propose to use `condition` instead of `errorClass` in two test suites: - SparkThrowableSuite - DateTimeFormatterHelperSuite ### Why are the changes needed? Because the changes from the PR #48027 conflict to #48058 and #48026, and tests in #48027 were passed earlier than the last PRs were merged to master. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By compiling and running the following tests locally: ``` $ build/sbt "test:testOnly *org.apache.spark.sql.catalyst.util.DateTimeFormatterHelperSuite" $ build/sbt "test:testOnly *SparkThrowableSuite" ``` ### Was this patch authored or co-authored using generative AI tooling? No. Closes #48061 from MaxGekk/fix-missing-errorClass. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
late LGTM. |
MaxGekk
added a commit
that referenced
this pull request
Sep 11, 2024
…Class` in `SqlScriptingInterpreterSuite` ### What changes were proposed in this pull request? In the PR, I propose to replace `errorClass` by `condition` in `SqlScriptingInterpreterSuite` ### Why are the changes needed? The changes from the PR #47756 conflict to #48027 ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By running the modified test: ``` $ build/sbt "test:testOnly *SqlScriptingInterpreterSuite" ``` ### Was this patch authored or co-authored using generative AI tooling? No. Closes #48072 from MaxGekk/fix-errorClass-REPEAT. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
This was referenced Sep 12, 2024
vkorukanti
pushed a commit
to delta-io/delta
that referenced
this pull request
Sep 18, 2024
) ## Description In the PR, I propose to use the `condition` parameter instead of `errorClass` in calls of `checkError` because `errorClass` was renamed in Spark by the PR apache/spark#48027. This PR fixes compilation issues like: ``` [error] checkError( [error] ^ [error] /home/runner/work/delta/delta/spark/src/test/scala/org/apache/spark/sql/delta/rowtracking/RowTrackingReadWriteSuite.scala:304:7: overloaded method checkError with alternatives: [error] (exception: org.apache.spark.SparkThrowable,condition: String,sqlState: Option[String],parameters: Map[String,String],context: RowTrackingReadWriteSuite.this.ExpectedContext)Unit <and> ``` ## How was this patch tested? By compiling locally. ## Does this PR introduce _any_ user-facing changes? No. This makes changes in tests only.
IvanK-db
pushed a commit
to IvanK-db/spark
that referenced
this pull request
Sep 20, 2024
…kError()` ### What changes were proposed in this pull request? In the PR, I propose to rename the `errorClass` parameter of the `checkError()` functions (and related and similar functions) to `condition` to follow the naming convention introduced by SPARK-46810. For example: ```scala checkError( exception = e, condition = "UNRESOLVED_COLUMN.WITH_SUGGESTION", parameters = Map("objectName" -> "`non_exist`", "proposal" -> "`i`, `j`")) ``` ### Why are the changes needed? To follow new naming convention introduced by apache#44902. ### Does this PR introduce _any_ user-facing change? No, the changes affect **only in tests**. ### How was this patch tested? By running the existing test suites and GAs. ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48027 from MaxGekk/rename-checkError-condition. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
IvanK-db
pushed a commit
to IvanK-db/spark
that referenced
this pull request
Sep 20, 2024
…Class` in `SparkThrowableSuite` and in `DateTimeFormatterHelperSuite` ### What changes were proposed in this pull request? In the PR, I propose to use `condition` instead of `errorClass` in two test suites: - SparkThrowableSuite - DateTimeFormatterHelperSuite ### Why are the changes needed? Because the changes from the PR apache#48027 conflict to apache#48058 and apache#48026, and tests in apache#48027 were passed earlier than the last PRs were merged to master. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By compiling and running the following tests locally: ``` $ build/sbt "test:testOnly *org.apache.spark.sql.catalyst.util.DateTimeFormatterHelperSuite" $ build/sbt "test:testOnly *SparkThrowableSuite" ``` ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48061 from MaxGekk/fix-missing-errorClass. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
attilapiros
pushed a commit
to attilapiros/spark
that referenced
this pull request
Oct 4, 2024
…kError()` ### What changes were proposed in this pull request? In the PR, I propose to rename the `errorClass` parameter of the `checkError()` functions (and related and similar functions) to `condition` to follow the naming convention introduced by SPARK-46810. For example: ```scala checkError( exception = e, condition = "UNRESOLVED_COLUMN.WITH_SUGGESTION", parameters = Map("objectName" -> "`non_exist`", "proposal" -> "`i`, `j`")) ``` ### Why are the changes needed? To follow new naming convention introduced by apache#44902. ### Does this PR introduce _any_ user-facing change? No, the changes affect **only in tests**. ### How was this patch tested? By running the existing test suites and GAs. ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48027 from MaxGekk/rename-checkError-condition. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
attilapiros
pushed a commit
to attilapiros/spark
that referenced
this pull request
Oct 4, 2024
…Class` in `SparkThrowableSuite` and in `DateTimeFormatterHelperSuite` ### What changes were proposed in this pull request? In the PR, I propose to use `condition` instead of `errorClass` in two test suites: - SparkThrowableSuite - DateTimeFormatterHelperSuite ### Why are the changes needed? Because the changes from the PR apache#48027 conflict to apache#48058 and apache#48026, and tests in apache#48027 were passed earlier than the last PRs were merged to master. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By compiling and running the following tests locally: ``` $ build/sbt "test:testOnly *org.apache.spark.sql.catalyst.util.DateTimeFormatterHelperSuite" $ build/sbt "test:testOnly *SparkThrowableSuite" ``` ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48061 from MaxGekk/fix-missing-errorClass. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
attilapiros
pushed a commit
to attilapiros/spark
that referenced
this pull request
Oct 4, 2024
…Class` in `SqlScriptingInterpreterSuite` ### What changes were proposed in this pull request? In the PR, I propose to replace `errorClass` by `condition` in `SqlScriptingInterpreterSuite` ### Why are the changes needed? The changes from the PR apache#47756 conflict to apache#48027 ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By running the modified test: ``` $ build/sbt "test:testOnly *SqlScriptingInterpreterSuite" ``` ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48072 from MaxGekk/fix-errorClass-REPEAT. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
himadripal
pushed a commit
to himadripal/spark
that referenced
this pull request
Oct 19, 2024
…kError()` ### What changes were proposed in this pull request? In the PR, I propose to rename the `errorClass` parameter of the `checkError()` functions (and related and similar functions) to `condition` to follow the naming convention introduced by SPARK-46810. For example: ```scala checkError( exception = e, condition = "UNRESOLVED_COLUMN.WITH_SUGGESTION", parameters = Map("objectName" -> "`non_exist`", "proposal" -> "`i`, `j`")) ``` ### Why are the changes needed? To follow new naming convention introduced by apache#44902. ### Does this PR introduce _any_ user-facing change? No, the changes affect **only in tests**. ### How was this patch tested? By running the existing test suites and GAs. ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48027 from MaxGekk/rename-checkError-condition. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
himadripal
pushed a commit
to himadripal/spark
that referenced
this pull request
Oct 19, 2024
…Class` in `SparkThrowableSuite` and in `DateTimeFormatterHelperSuite` ### What changes were proposed in this pull request? In the PR, I propose to use `condition` instead of `errorClass` in two test suites: - SparkThrowableSuite - DateTimeFormatterHelperSuite ### Why are the changes needed? Because the changes from the PR apache#48027 conflict to apache#48058 and apache#48026, and tests in apache#48027 were passed earlier than the last PRs were merged to master. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By compiling and running the following tests locally: ``` $ build/sbt "test:testOnly *org.apache.spark.sql.catalyst.util.DateTimeFormatterHelperSuite" $ build/sbt "test:testOnly *SparkThrowableSuite" ``` ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48061 from MaxGekk/fix-missing-errorClass. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
himadripal
pushed a commit
to himadripal/spark
that referenced
this pull request
Oct 19, 2024
…Class` in `SqlScriptingInterpreterSuite` ### What changes were proposed in this pull request? In the PR, I propose to replace `errorClass` by `condition` in `SqlScriptingInterpreterSuite` ### Why are the changes needed? The changes from the PR apache#47756 conflict to apache#48027 ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? By running the modified test: ``` $ build/sbt "test:testOnly *SqlScriptingInterpreterSuite" ``` ### Was this patch authored or co-authored using generative AI tooling? No. Closes apache#48072 from MaxGekk/fix-errorClass-REPEAT. Authored-by: Max Gekk <max.gekk@gmail.com> Signed-off-by: Max Gekk <max.gekk@gmail.com>
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.
What changes were proposed in this pull request?
In the PR, I propose to rename the
errorClass
parameter of thecheckError()
functions (and related and similar functions) tocondition
to follow the naming convention introduced by SPARK-46810.For example:
Why are the changes needed?
To follow new naming convention introduced by #44902.
Does this PR introduce any user-facing change?
No, the changes affect only in tests.
How was this patch tested?
By running the existing test suites and GAs.
Was this patch authored or co-authored using generative AI tooling?
No.