xanderbailey commented on code in PR #3624:
URL: https://github.com/apache/iceberg-python/pull/3624#discussion_r4813105802
##########
pyiceberg/table/update/snapshot.py:
##########
@@ -348,21 +348,22 @@ def _commit(self) -> UpdatesAndRequirements:
manifest_list_file_path =
location_provider.new_metadata_location(file_name)
self._written_manifest_lists.append(manifest_list_file_path)
+ first_row_id: int | None = None
+
+ if self._transaction.table_metadata.format_version >= 3:
+ first_row_id = self._transaction.table_metadata.next_row_id
Review Comment:
I think `next_row_id` can be `None` here as it currently stands, e.g. a V3
table from `new_table_metadata`, so this fails with `First-row-id is required
for V3 tables`.
https://github.com/apache/iceberg-python/pull/3551/changes#diff-a7fbd8c6b0564308ca872ba479f0e240ff2c893d15776a14e52b91b48e9ac470R724
seems to fix it and
https://github.com/apache/iceberg-python/pull/3623/changes#diff-769b43e1d8beaa86141f694679de2bbea3604a65f987a9acd7d9e9efca193b7eR345
does this correctly also so maybe this is fine as long as we land everything.
Please check my logic here.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]