ox opened a new pull request, #2343:
URL: https://github.com/apache/iceberg-python/pull/2343

   Closes #2342
   
   # Rationale for this change
   
   The OpenAPI spec specifies that `snapshot-id` is required [1], even if it's 
`null`. The current code omits the field b/c `exclude_none=True` is set for all 
models that extend `IcebergBaseModel`. Setting `exclude=False` on the field 
doesn't override the behavior and thus the model needs to control it's own 
serialization. This is the only model I know of so far that has this "required 
null" problem so I held back from making another class for this model to extend.
   
   # Are these changes tested?
   
   Yes
   
   # Are there any user-facing changes?
   
   Set `snapshot-id: null` when committing tables that don't have a current 
snapshot-id.
   
   [1]: 
https://github.com/apache/iceberg/blob/main/open-api/rest-catalog-open-api.yaml#L3138-L3155
   


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

Reply via email to