nathadfield commented on code in PR #63884:
URL: https://github.com/apache/airflow/pull/63884#discussion_r3167060565
##########
airflow-core/src/airflow/api_fastapi/core_api/routes/ui/config.py:
##########
@@ -62,6 +62,7 @@ def get_configs() -> ConfigResponse:
"external_log_name": getattr(task_log_reader.log_handler, "log_name",
None),
"theme": loads(conf.get("api", "theme", fallback="{}")) or None,
"multi_team": conf.getboolean("core", "multi_team"),
+ "rerun_with_latest_version": conf.getboolean("core",
"rerun_with_latest_version", fallback=False),
Review Comment:
Changed `fallback=False` to return `None` when the option isn't explicitly
set (using `conf.has_option`). Now the UI hook properly sees null from global
config and falls through to its own fallback (`true` for backfills, `false` for
clear/rerun).
##########
airflow-core/src/airflow/ui/openapi-gen/requests/types.gen.ts:
##########
@@ -1880,6 +1881,7 @@ export type ConfigResponse = {
external_log_name?: string | null;
theme: Theme | null;
multi_team: boolean;
+ rerun_with_latest_version: boolean;
Review Comment:
Updated `rerun_with_latest_version` to `boolean | null` (in the response
model, OpenAPI spec, and generated types) so the hook's `??` chain can
correctly fall through to the fallback argument when the config isn't set.
--
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]