diff --git a/atproto/xrpc_client/models/base.py b/atproto/xrpc_client/models/base.py index ba277367..50105ab7 100644 --- a/atproto/xrpc_client/models/base.py +++ b/atproto/xrpc_client/models/base.py @@ -27,7 +27,9 @@ def __getitem__(self, item: str) -> t.Any: @model_validator(mode='after') def __alert_about_extra_fields(self) -> 'ModelBase': - if self.model_extra and os.environ.get('ATPROTO_LEXICON_WARN', '1') == '1': + # used for debugging purposes because gives false positives due to the way pydantic works + + if self.model_extra and os.environ.get('ATPROTO_LEXICON_WARN', '0') == '1': warnings.warn( f'Extra fields found in the object of type {type(self)}: {self.model_extra}. ' # noqa: S608 f'Probably you are using the old version of SDK. '