You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "potiuk (via GitHub)" <gi...@apache.org> on 2026/06/02 22:50:33 UTC
[PR] Restrict BASE_TRIGGER deserialization to BaseTrigger subclasses [airflow]
potiuk opened a new pull request, #67926:
URL: https://github.com/apache/airflow/pull/67926
When loading a serialized DAG, the `BASE_TRIGGER` deserialization branch in `BaseSerialization.deserialize` imported the stored class path and instantiated it without checking it is actually a `BaseTrigger` subclass. This restricts that path to `BaseTrigger` subclasses (raising `ValueError` otherwise), matching the encode side which only emits `BASE_TRIGGER` for `BaseTrigger` instances.
### Tests
- [x] Added `test_base_trigger_deserialization_rejects_non_trigger_class` — a non-`BaseTrigger` class path is rejected.
- [x] Existing `test_trigger_kwargs_not_deserialised_through_serdag` still passes.
##### Was generative AI tooling used to co-author this PR?
- [X] Yes — Claude Opus 4.8 (1M context)
Generated-by: Claude Opus 4.8 (1M context) following the guidelines at
https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Restrict BASE_TRIGGER deserialization to trusted classes (validate before import) [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk commented on PR #67926:
URL: https://github.com/apache/airflow/pull/67926#issuecomment-4701220114
https://github.com/apache/airflow/pull/68528 is a better fix.
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Restrict BASE_TRIGGER deserialization to BaseTrigger subclasses [airflow]
Posted by "ashb (via GitHub)" <gi...@apache.org>.
ashb commented on PR #67926:
URL: https://github.com/apache/airflow/pull/67926#issuecomment-4688007286
Why exactly does this matter? Its user code operating in the triggerer - if they want to play silly games let them?
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Restrict BASE_TRIGGER deserialization to trusted classes (validate before import) [airflow]
Posted by "potiuk (via GitHub)" <gi...@apache.org>.
potiuk closed pull request #67926: Restrict BASE_TRIGGER deserialization to trusted classes (validate before import)
URL: https://github.com/apache/airflow/pull/67926
--
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: commits-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org