diff --git a/airbyte_cdk/sources/types.py b/airbyte_cdk/sources/types.py index a922d271..c0640d43 100644 --- a/airbyte_cdk/sources/types.py +++ b/airbyte_cdk/sources/types.py @@ -152,3 +152,6 @@ def __json_serializable__(self) -> Any: def __hash__(self) -> int: return hash(orjson.dumps(self._stream_slice, option=orjson.OPT_SORT_KEYS)) + + def __bool__(self): + return bool(self._stream_slice) or bool(self._extra_fields)