You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "HonahX (via GitHub)" <gi...@apache.org> on 2024/03/24 19:01:57 UTC

[PR] [Bug Fix] Fix TableMetadataV1 Validators [iceberg-python]

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

   When working on https://github.com/apache/iceberg-python/pull/498, I noticed that `new_table_metadata` cannot correctly initialize `partition_specs` and `sort_oders` fields for V1 Metadata. For example:
   
   ```python
       schema = ... 
       
      partition_spec = PartitionSpec(
           PartitionField(source_id=22, field_id=1022, transform=IdentityTransform(), name="bar"), spec_id=10
       )
   
       sort_order = SortOrder(
           SortField(source_id=10, transform=IdentityTransform(), direction=SortDirection.ASC, null_order=NullOrder.NULLS_LAST),
           order_id=10,
       )
   
       actual = new_table_metadata(
           schema=schema,
           partition_spec=partition_spec,
           sort_order=sort_order,
           location="s3://some_v1_location/",
           properties={'format-version': "1"},
       )
   --------   
   print(actual.partition_specs)
   --- output ---
   [PartitionSpec(spec_id=0)]
   
   --------
   print(actual.sort_orders)
   --- output ---
   [SortOrder(order_id=0)]
   
   ```
   
   We may update the validators to consider both the field name and its alias. (ex "sort_orders" and "sort-orders") so that the validators won't override any initialized fields.
   
   cc: @Fokko @amogh-jahagirdar 


-- 
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-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] [Bug Fix] Fix TableMetadataV1 Validators [iceberg-python]

Posted by "HonahX (via GitHub)" <gi...@apache.org>.
HonahX commented on PR #544:
URL: https://github.com/apache/iceberg-python/pull/544#issuecomment-2017503525

   > We might want to consider a release to get this bug fix out to the public. WDYT?
   
   That's a great idea! Shall we create a 0.6.1 milestone or a 0.6.1 proposal in dev-mail-list? I have just opened another bug-fix PR: https://github.com/apache/iceberg-python/pull/547 and I also saw other bug-fix PR may be worth to be added (e.g. https://github.com/apache/iceberg-python/pull/545 ). 
   
   BTW, If we finally decide to do the release, I am interested in becoming the release manager. :)


-- 
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-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] [Bug Fix] Fix TableMetadataV1 Validators [iceberg-python]

Posted by "Fokko (via GitHub)" <gi...@apache.org>.
Fokko commented on PR #544:
URL: https://github.com/apache/iceberg-python/pull/544#issuecomment-2017682157

   @HonahX Yes, that sounds good. There is no formal process for starting a release, just someone needs to take the time to drive the process. Great that you want to become a release manager :D
   
   I would also be open to just running 0.7.0 from the main branch. There is already a lot of cool stuff that would be great to get out to the public.


-- 
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-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org


Re: [PR] [Bug Fix] Fix TableMetadataV1 Validators [iceberg-python]

Posted by "Fokko (via GitHub)" <gi...@apache.org>.
Fokko merged PR #544:
URL: https://github.com/apache/iceberg-python/pull/544


-- 
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-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org