Skip to content

Commit 796dbe5

Browse files
kevinjqliusungwy
authored andcommitted
[bug] [REST] Dont remove identifier root (apache#1172)
* dont remove identifier root * remove catalog in identifier tuple
1 parent c4cafeb commit 796dbe5

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

pyiceberg/catalog/rest.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -575,6 +575,7 @@ def _create_table(
575575
fresh_partition_spec = assign_fresh_partition_spec_ids(partition_spec, iceberg_schema, fresh_schema)
576576
fresh_sort_order = assign_fresh_sort_order_ids(sort_order, iceberg_schema, fresh_schema)
577577

578+
identifier = self._identifier_to_tuple_without_catalog(identifier)
578579
namespace_and_table = self._split_identifier_for_path(identifier)
579580
if location:
580581
location = location.rstrip("/")
@@ -656,6 +657,7 @@ def register_table(self, identifier: Union[str, Identifier], metadata_location:
656657
Raises:
657658
TableAlreadyExistsError: If the table already exists
658659
"""
660+
identifier = self._identifier_to_tuple_without_catalog(identifier)
659661
namespace_and_table = self._split_identifier_for_path(identifier)
660662
request = RegisterTableRequest(
661663
name=namespace_and_table["table"],

0 commit comments

Comments
 (0)