rdblue commented on code in PR #4926: URL: https://github.com/apache/iceberg/pull/4926#discussion_r934047817
########## core/src/main/java/org/apache/iceberg/SnapshotProducer.java: ########## @@ -167,8 +200,7 @@ protected void validate(TableMetadata currentMetadata) { @Override public Snapshot apply() { refresh(); - Long parentSnapshotId = base.currentSnapshot() != null ? - base.currentSnapshot().snapshotId() : null; + Long parentSnapshotId = base.ref(targetBranch) != null ? base.ref(targetBranch).snapshotId() : null; Review Comment: This should be the existing branch state, the current snapshot (if creating the branch), or null. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org