nastra commented on code in PR #10082:
URL: https://github.com/apache/iceberg/pull/10082#discussion_r1551437288


##########
core/src/main/java/org/apache/iceberg/jdbc/JdbcTableOperations.java:
##########
@@ -138,7 +138,7 @@ public void doCommit(TableMetadata base, TableMetadata 
metadata) {
       throw new UncheckedSQLException(e, "Database warning");
     } catch (SQLException e) {
       // SQLite doesn't set SQLState or throw 
SQLIntegrityConstraintViolationException
-      if (e.getMessage().contains("constraint failed")) {
+      if (e.getMessage() != null && e.getMessage().contains("constraint 
failed")) {

Review Comment:
   please add tests that exercise each change here (similar to the test in 
https://github.com/apache/iceberg/pull/10069)



-- 
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

Reply via email to