ferruzzi commented on PR #68195:
URL: https://github.com/apache/airflow/pull/68195#issuecomment-4663615343
This doesn't feel right. Where in the code are you actually running into
this failure? `validate_schema` is (currently??) only ever called before the
Deadline dict is converted to a UUID.
It looks like this is happening because `test_write_dag` is using
`LazyDeserializedDAG` twice, once before the dict>UUID migration then again
after and that is causing a mismatch. If that's the case then this isn't
actually fixing the bug, it's just hiding it. I think a better fix would be to
actually fix write_dag so that `_generate_deadline_uuids` is working on a
deepcopy of dag.data and not pulling the rug out from under
`LazyDeserializedDAG` by changing things in place. Something like
```python
working_data = copy.deepcopy(dag.data)
deadline_uuid_mapping = cls._generate_deadline_uuids(working_data)
```
--
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]