Subham-KRLX commented on code in PR #62060:
URL: https://github.com/apache/airflow/pull/62060#discussion_r2819996186
##########
airflow-core/src/airflow/ui/src/components/FlexibleForm/FieldDropdown.tsx:
##########
@@ -25,12 +25,15 @@ import { paramPlaceholder, useParamStore } from
"src/queries/useParamStore";
import type { FlexibleFormElementProps } from ".";
-const labelLookup = (key: string, valuesDisplay: Record<string, string> |
undefined): string => {
+const labelLookup = (key: number | string | null, valuesDisplay:
Record<string, string> | undefined): string => {
+ // Convert null to string to avoid issues with object key lookup
+ const stringKey = key === null ? "null" : String(key);
Review Comment:
I have updated the implementation to use a constant __null__ internally to
avoid potential clashes with literal string values. I have also fixed the
values_display lookup logic to correctly handle None keys (by adding a fallback
check for 'None'). Additionally I ran a full suite of static checks
(prek/eslint) to fix all formatting and linting issues.
--
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]