mattwang44 opened a new pull request, #75379:
URL: https://github.com/apache/airflow/pull/75379
Passing a bare string where the Dag expects a collection was iterated
character by character:
- `DAG(tags="finance")` (and `@asset(tags="finance")`, which forwards its
tags) produced the tags `{'a', 'c', 'e', 'f', 'i', 'n'}`. As a side effect, a
single over-long string tag also bypassed the 100-character tag length check.
- `DAG(allowed_run_types="manual")` failed with `ValueError: 'm' is not a
valid DagRunType`, although a single `DagRunType` member was already accepted.
This treats a bare string as a single value, the same way
`template_searchpath` already does via `_convert_str_to_tuple`. I chose
wrapping over raising `TypeError` because the intent is unambiguous, it matches
the existing converters, and no Dag can rely on the character-splitting
behaviour, so nothing that works today breaks. `tags=""` keeps producing an
empty set.
---
##### Was generative AI tooling used to co-author this PR?
- [X] Yes — Claude Code (Claude Opus 5.5), following [the
guidelines](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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]