Trigger UI clamps Param min/max instead of rejecting out-of-range values
メンテナーはふだん 1 日以内に返信
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 72/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- python, react, typescript
調査の方向性
Airflow 3 の Trigger フォームで FieldNumber.tsx から始めます。issue では、NumberInput に渡されるスキーマの minimum と maximum が指摘されています。この入力欄が入力値をどのように保持するか、またフォーム送信時に Param JSON Schema のエラーをどのように報告するかを追い、ドキュメントに記載された Trigger の動作と比較します。範囲外の値がエラーとともに拒否され、DagRun を作成できない状態になれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Under which category would you file this issue?
Airflow Core
Apache Airflow version
3.3.1
What happened and how to reproduce it?
When a DAG Param sets a minimum or maximum on an integer field, typing a value outside that range in the Airflow 3 Trigger form does not fail the trigger. The form quietly changes the number to fit the allowed range, then submits it. The run starts with the corrected value instead of being blocked.
Example DAG:
from airflow.sdk import Param, dag, task
@dag(
dag_id="repro_param_minmax_clamp",
schedule=None,
start_date=None,
catchup=False,
params={
"hold_seconds": Param(180, type="integer", minimum=1, maximum=600),
},
)
def repro():
@task
def show(params=None):
print((params or {}).get("hold_seconds"))
show()
repro()
How to reproduce
- Deploy the DAG above on Airflow 3.3.1 (also present on current
mainFieldNumber.tsx:max={param.schema.maximum},min={param.schema.minimum}). - Open Trigger DAG in the UI.
- Type
6666inhold_seconds(abovemaximum=600). - Trigger the DAG.
- Observe: the field/value becomes
600(or similar clamp), the run starts successfully, and the task prints600. - Repeat with
0or-5(belowminimum=1): the UI clamps up to1instead of blocking the trigger.
Contrast: CLI/API correctly reject the same values:
airflow dags trigger repro_param_minmax_clamp --conf '{"hold_seconds": 6666}'
# ParamValidationError: 6666 is greater than the maximum of 600
airflow dags trigger repro_param_minmax_clamp --conf '{"hold_seconds": 0}'
# ParamValidationError: 0 is less than the minimum of 1
Docs say invalid params should show a warning and not create a DagRun. The UI path never sends the invalid value, so that validation never runs.
What you think should happen instead?
- User can type a value outside
[minimum, maximum](or the field keeps the invalid typed value). - On Trigger, the UI/API fails validation (inline or form error), same as CLI/API
ParamValidationError. - No DagRun is created until the value is corrected.
Suggested direction: do not pass schema min/max into NumberInput as hard clamps (or disable clamp behavior), and rely on Param JSON Schema validation at submit time for both min and max, consistent with the documented trigger behavior and with the backend.
Operating System
Ubuntu 24.04.4 LTS
Deployment
Docker-Compose
Apache Airflow Provider(s)
No response
Versions of Apache Airflow Providers
No response
Official Helm Chart version
No response
Kubernetes Version
No response
Helm Chart configuration
No response
Docker Image customizations
No response
Anything else?
No response
Are you willing to submit PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct
- 主要言語
- Python
- スター
- 47.3k
- フォーク
- 18.1k
- 平均マージ
- 19時間 26分
- マージ済み PR(30日)
- 639
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
apache/airflow のほかの issue
-
kind:bug needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
apache/airflow#75858 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
`@task.pyspark` does not template `config_kwargs` and `conn_id`対応中かも @sdaberdaku が 1 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 79/100
メンテナーはふだん 1 日以内に返信
-
Deadline Alert: No support for SmtpNotifier対応中かも @LiaoAB が 4 日前に担当しました。 オープンkind:bug needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
apache/airflow#75452 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
RedactedIO leaks secret bytes to stdout対応中かも @ShivanshhhG が 9 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
apache/airflow#75069 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Task supervisor raises TypeError when a task log event has a key named target or msg, orphaning the task process and recording a successful task as failed対応中かも @liwenjie200543 が 10 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
apache/airflow#75017 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
btclib-org/btclib-node#2132 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
freelawproject/juriscraper#2367 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
infra tech-debt
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
needs-triage
難易度 1/5 1時間未満 初心者へのやさしさ 78/100
gke-labs/kube-agents#4190 ·
メンテナーはふだん 1 日以内に返信