hililiwei commented on code in PR #8174:
URL: https://github.com/apache/iceberg/pull/8174#discussion_r1302343373
##########
python/pyiceberg/schema.py:
##########
@@ -201,7 +203,7 @@ def find_type(self, name_or_id: Union[str, int],
case_sensitive: bool = True) ->
@property
def highest_field_id(self) -> int:
- return visit(self.as_struct(), _FindLastFieldId())
+ return max(self._lazy_id_to_name.keys(), default=0)
Review Comment:
The old way didn't get the highest field id correctly, so I changed it.
--
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]