Skip to content

Commit 1f95feb

Browse files
Fix test error message and scalafmt formatting
1 parent 5d76748 commit 1f95feb

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

kernel/kernel-api/src/main/java/io/delta/kernel/internal/snapshot/SnapshotManager.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,14 @@ public SnapshotImpl getSnapshotForTimestamp(
147147
public static void verifyDeltaVersionsContiguous(List<Long> versions, Path tablePath) {
148148
for (int i = 1; i < versions.size(); i++) {
149149
if (versions.get(i) != versions.get(i - 1) + 1) {
150+
long expectedVersion = versions.get(i - 1) + 1;
151+
long foundVersion = versions.get(i);
150152
throw new InvalidTableException(
151153
tablePath.toString(),
152-
String.format("Missing delta files: versions are not contiguous: (%s)", versions));
154+
String.format(
155+
"Missing delta files: versions are not contiguous. Expected version %d after "
156+
+ "version %d, but found version %d. All versions: %s",
157+
expectedVersion, versions.get(i - 1), foundVersion, versions));
153158
}
154159
}
155160
}

0 commit comments

Comments
 (0)