Skip to content

Commit

Permalink
[MINOR] Fix the grammar of some comments on renaming error classes
Browse files Browse the repository at this point in the history
### What changes were proposed in this pull request?

Minor fixes to the English of some comments I added in #44920.

### Why are the changes needed?

Proper English -- OK, not _proper_, but more correct at least -- makes things easier to read.

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

Not tested beyond CI.

### Was this patch authored or co-authored using generative AI tooling?

No.

Closes #46321 from nchammas/error-cond-typo.

Authored-by: Nicholas Chammas <nicholas.chammas@gmail.com>
Signed-off-by: Hyukjin Kwon <gurwls223@apache.org>
  • Loading branch information
nchammas authored and HyukjinKwon committed May 1, 2024
1 parent f86a519 commit e521d3c
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ private[spark] object ErrorMessageFormat extends Enumeration {
private[spark] object SparkThrowableHelper {
val errorReader = new ErrorClassesJsonReader(
// Note that though we call them "error classes" here, the proper name is "error conditions",
// hence why the name of the JSON file different. We will address this inconsistency as part
// hence why the name of the JSON file is different. We will address this inconsistency as part
// of this ticket: https://issues.apache.org/jira/browse/SPARK-47429
Seq(SparkClassUtils.getSparkClassLoader.getResource("error/error-conditions.json")))

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ private object KafkaExceptionsHelper {
val errorClassesJsonReader: ErrorClassesJsonReader =
new ErrorClassesJsonReader(
// Note that though we call them "error classes" here, the proper name is "error conditions",
// hence why the name of the JSON file different. We will address this inconsistency as part
// of this ticket: https://issues.apache.org/jira/browse/SPARK-47429
// hence why the name of the JSON file is different. We will address this inconsistency as
// part of this ticket: https://issues.apache.org/jira/browse/SPARK-47429
Seq(getClass.getClassLoader.getResource("error/kafka-error-conditions.json")))
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class SparkThrowableSuite extends SparkFunSuite {

private val errorJsonFilePath = getWorkspaceFilePath(
// Note that though we call them "error classes" here, the proper name is "error conditions",
// hence why the name of the JSON file different. We will address this inconsistency as part
// hence why the name of the JSON file is different. We will address this inconsistency as part
// of this ticket: https://issues.apache.org/jira/browse/SPARK-47429
"common", "utils", "src", "main", "resources", "error", "error-conditions.json")

Expand Down
2 changes: 1 addition & 1 deletion python/pyspark/errors/error_classes.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import importlib.resources

# Note: Though we call them "error classes" here, the proper name is "error conditions",
# hence why the name of the JSON file different.
# hence why the name of the JSON file is different.
# For more information, please see: https://issues.apache.org/jira/browse/SPARK-46810
# This discrepancy will be resolved as part of: https://issues.apache.org/jira/browse/SPARK-47429
ERROR_CLASSES_JSON = (
Expand Down

0 comments on commit e521d3c

Please sign in to comment.