Skip to content

Conversation

@SakshamSinghal20
Copy link

This PR resolves an issue where translation keys for "Blocking Dependencies" in the Task Instance Details panel were missing (e.g., dag.blockingDeps.title, dag.blockingDeps.dependency), displaying raw keys instead of the localized text.

The dag and tasks translation files existed in the locales directory but were not registered in the i18n configuration (config.ts), preventing them from being loaded. This change adds both namespaces to the configuration to ensure the translations are applied correctly.

closes: #61314


Was generative AI tooling used to co-author this PR?

No

Copy link
Contributor

@RoyLee1224 RoyLee1224 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR! However, I think the current changes do not seem to address the root cause.

The issue is that the BlockingDeps component needs to load the dag namespace to access the keys in airflow-core/src/airflow/ui/public/i18n/locales/en/dag.json.

To fix this, please revert the changes in this PR and instead modify BlockingDeps.tsx as follows:

  1. Update the hook to load the namespace:
const { t: translate } = useTranslation("dag");
  1. Remove the dag. prefix from the keys (since we are already in the dag namespace):
// Change this:
{translate("dag.blockingDeps.title")}
// To this:
{translate("blockingDeps.title")}

(Please apply this pattern to dependency and reason headers as well.)

@SakshamSinghal20
Copy link
Author

Thank you so much for letting me know I will fix this ASAP.

- Revert changes to global i18n config
- Load 'dag' namespace specifically in BlockingDeps component
- Update translation keys to match namespace context
@SakshamSinghal20
Copy link
Author

@RoyLee1224 I hope The following commit will solve this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:UI Related to UI/UX. For Frontend Developers.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Task Scheduling Blocking Depdendency Reason missing translation keys

2 participants