[SPARK-42253][PYTHON] Add test for detecting duplicated error class#39821
Closed
itholic wants to merge 3 commits intoapache:masterfrom
Closed
[SPARK-42253][PYTHON] Add test for detecting duplicated error class#39821itholic wants to merge 3 commits intoapache:masterfrom
itholic wants to merge 3 commits intoapache:masterfrom
Conversation
HyukjinKwon
approved these changes
Jan 31, 2023
zhengruifeng
approved these changes
Jan 31, 2023
Member
|
Merged to master and branch-3.4. |
HyukjinKwon
added a commit
that referenced
this pull request
Feb 1, 2023
### What changes were proposed in this pull request? This PR proposes to add test for detecting duplicated name of error classes to keep the error class unique. ### Why are the changes needed? The name of error class should be unique, so we should check if it's duplicated or not. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Manually test in case `COLUMN_IN_LIST` is duplicated as below: ```shell ====================================================================== FAIL [0.006s]: test_error_classes_duplicated (pyspark.errors.tests.test_errors.ErrorsTest) ---------------------------------------------------------------------- Traceback (most recent call last): ... AssertionError: False is not true : Duplicate error class: COLUMN_IN_LIST ---------------------------------------------------------------------- Ran 2 tests in 0.007s FAILED (failures=1) ``` Closes #39821 from itholic/SPARK-42253. Lead-authored-by: itholic <haejoon.lee@databricks.com> Co-authored-by: Hyukjin Kwon <gurwls223@gmail.com> Signed-off-by: Hyukjin Kwon <gurwls223@apache.org> (cherry picked from commit 4d37e78) Signed-off-by: Hyukjin Kwon <gurwls223@apache.org>
snmvaughan
pushed a commit
to snmvaughan/spark
that referenced
this pull request
Jun 20, 2023
### What changes were proposed in this pull request? This PR proposes to add test for detecting duplicated name of error classes to keep the error class unique. ### Why are the changes needed? The name of error class should be unique, so we should check if it's duplicated or not. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Manually test in case `COLUMN_IN_LIST` is duplicated as below: ```shell ====================================================================== FAIL [0.006s]: test_error_classes_duplicated (pyspark.errors.tests.test_errors.ErrorsTest) ---------------------------------------------------------------------- Traceback (most recent call last): ... AssertionError: False is not true : Duplicate error class: COLUMN_IN_LIST ---------------------------------------------------------------------- Ran 2 tests in 0.007s FAILED (failures=1) ``` Closes apache#39821 from itholic/SPARK-42253. Lead-authored-by: itholic <haejoon.lee@databricks.com> Co-authored-by: Hyukjin Kwon <gurwls223@gmail.com> Signed-off-by: Hyukjin Kwon <gurwls223@apache.org> (cherry picked from commit 4d37e78) Signed-off-by: Hyukjin Kwon <gurwls223@apache.org>
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.
What changes were proposed in this pull request?
This PR proposes to add test for detecting duplicated name of error classes to keep the error class unique.
Why are the changes needed?
The name of error class should be unique, so we should check if it's duplicated or not.
Does this PR introduce any user-facing change?
No.
How was this patch tested?
Manually test in case
COLUMN_IN_LISTis duplicated as below: