Skip to content

Commit

Permalink
Minor exception message changes
Browse files Browse the repository at this point in the history
  • Loading branch information
watfordkcf committed Aug 11, 2023
1 parent c78daef commit 22df14f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ public void write(
} else {
if (!fs.exists(prevPath)) {
throw new java.nio.file.FileSystemException(
String.format("previous commit %s doesn't exist", prevPath)
String.format("previous commit %s doesn't exist on the file system but does in the external log store", prevPath)
);
}
}
Expand All @@ -220,7 +220,7 @@ public void write(
if (entry.get().complete && !fs.exists(path)) {
throw new java.nio.file.FileSystemException(
String.format(
"Old entries for table %s still exist in the external store",
"Old entries for table %s still exist in the external log store",
tablePath
)
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ class ExternalLogStoreSuite extends org.apache.spark.sql.delta.PublicLogStoreSui
val e = intercept[java.nio.file.FileSystemException] {
store.write(delta1, Iterator("one"), overwrite = false, sessionHadoopConf)
}
assert(e.getMessage == s"previous commit $delta0 doesn't exist")
assert(e.getMessage == s"previous commit $delta0 doesn't exist on the file system but does in the external log store")
}
}

Expand Down Expand Up @@ -236,7 +236,7 @@ class ExternalLogStoreSuite extends org.apache.spark.sql.delta.PublicLogStoreSui
}.getMessage

val tablePath = path.getParent.getParent
assert(e == s"Old entries for table $tablePath still exist in the external store")
assert(e == s"Old entries for table $tablePath still exist in the external log store")
}
}

Expand Down

0 comments on commit 22df14f

Please sign in to comment.