Repository navigation
fix: create the table's own namespace for qualified table names - #381
Open
nirmalpatel008 wants to merge 1 commit into
Open
nirmalpatel008 wants to merge 1 commit into
nirmalpatel008 wants to merge 1 commit into
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
Contributor
|
All contributors have signed the CLA ✍️ ✅ |
Author
|
I have read the CLA Document and I hereby sign the CLA |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
tables() accepts a qualified name such as "sales.orders", and load() resolves it correctly. But create() and create_if_not_exists() always create the default namespace (or the namespace argument), not the namespace in the name. So tables("sales.orders").create(schema) fails with NoSuchNamespaceError: ('sales',), and it leaves an empty default namespace behind. On Glue or S3 Tables, that’s a stray database.
This change creates the namespace taken from the resolved table name instead. Unqualified names behave as before.
Tests: added cases for create and create_if_not_exists with a qualified name and a nested one (analytics.sales.orders). They fail before the change and pass after. Ran the table and storage tests locally with the pinned PyIceberg 0.11.1 and Polars 1.39.3: 130 passed.