kaxil commented on code in PR #74421:
URL: https://github.com/apache/airflow/pull/74421#discussion_r4353810684
##########
task-sdk/src/airflow/sdk/execution_time/context.py:
##########
@@ -756,13 +756,7 @@ def _extract_get_response(self, resp: Any, key: str,
default: JsonValue) -> Json
if backend is not None and isinstance(stored, dict) and (ref :=
_unwrap_external_ref(stored)):
Review Comment:
Your example is exactly the wrapper shape, so a stricter check on its own
wouldn't catch it. I made `set()` reject a value with a top-level
`__airflow_state_ref__` key, and also made `_unwrap_external_ref` require
exactly `{marker: str}` like you suggested, which handles dicts with extra keys
written through the REST API. Something written through the API in exactly that
shape still reads as a ref, but that's been true since #67530. Tests in 788b03b.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]