Skip to content

Commit 29ec58d

Browse files
committed
fix: do not return hidden iceberg columns
1 parent 635f6d5 commit 29ec58d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

awswrangler/catalog/_utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,9 @@ def _sanitize_name(name: str) -> str:
3434
def _extract_dtypes_from_table_details(response: "GetTableResponseTypeDef") -> dict[str, str]:
3535
dtypes: dict[str, str] = {}
3636
for col in response["Table"]["StorageDescriptor"]["Columns"]:
37-
dtypes[col["Name"]] = col["Type"]
37+
# Do not return "hidden" iceberg columns
38+
if col.get("Parameters", {}).get("iceberg.field.current") != "false":
39+
dtypes[col["Name"]] = col["Type"]
3840
if "PartitionKeys" in response["Table"]:
3941
for par in response["Table"]["PartitionKeys"]:
4042
dtypes[par["Name"]] = par["Type"]

0 commit comments

Comments
 (0)