From 334680532626afde380574d6d612bc156ca714a0 Mon Sep 17 00:00:00 2001 From: "Chris (He/Him)" Date: Fri, 20 Mar 2026 15:25:04 +0000 Subject: [PATCH] fix: relax AttributeDef.default_value and index_type_es_fields to Any Atlas API responses can return non-string scalars for these fields: - default_value: native bool/int (e.g. false, 0) where str was expected - index_type_es_fields values: int (e.g. {"ignore_above": 256}) where str was expected msgspec strict=False does not coerce int/bool -> str, causing ValidationError on live typedef responses. Widening to Any lets the decoder accept whatever the API returns without pre-decode traversal. --- pyatlan_v9/model/typedef.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyatlan_v9/model/typedef.py b/pyatlan_v9/model/typedef.py index b903ad2a8..24d618401 100644 --- a/pyatlan_v9/model/typedef.py +++ b/pyatlan_v9/model/typedef.py @@ -627,7 +627,7 @@ def creator( description: Union[str, None, msgspec.UnsetType] = msgspec.UNSET """Description of the attribute definition.""" - default_value: Union[str, None, msgspec.UnsetType] = msgspec.UNSET + default_value: Union[Any, None, msgspec.UnsetType] = msgspec.UNSET """Default value for this attribute (if any).""" display_name: Union[str, None, msgspec.UnsetType] = msgspec.UNSET @@ -674,7 +674,7 @@ def creator( ) """Internal use only.""" - index_type_es_fields: Union[Dict[str, Dict[str, str]], None, msgspec.UnsetType] = ( + index_type_es_fields: Union[Dict[str, Dict[str, Any]], None, msgspec.UnsetType] = ( msgspec.field(default=msgspec.UNSET, name="indexTypeESFields") ) """Internal use only."""