fix(translations): Fix language switching when default language is not English
SUMMARY
In Flask App Builder, menu translation is already integrated using the label field. However, in Apache Superset, during the initial setup, the label field was translated according to the default language. Upon switching to a different language, the system attempted to translate the already translated value. Since the translated key (in this case, Russian) did not exist in the dictionary, this caused an issue. Therefore, I removed the translation from the application initialization process.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
TESTING INSTRUCTIONS
- Set BABEL_DEFAULT_LOCALE = "ru".
- Start the application.
- Switch the interface language to English.
- Verify the translations.
ADDITIONAL INFORMATION
- [x] Has associated issue: Fixes #29882
- [ ] Required feature flags:
- [ ] Changes UI
- [ ] Includes DB Migration (follow approval process in SIP-59)
- [ ] Migration is atomic, supports rollback & is backwards-compatible
- [ ] Confirm DB migration upgrade and downgrade tested
- [ ] Runtime estimates and downtime expectations provided
- [ ] Introduces new feature or API
- [ ] Removes existing feature or API
Codecov Report
:white_check_mark: All modified and coverable lines are covered by tests.
:white_check_mark: Project coverage is 83.65%. Comparing base (76d897e) to head (e6f9cdb).
:warning: Report is 2556 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #30015 +/- ##
===========================================
+ Coverage 60.48% 83.65% +23.16%
===========================================
Files 1931 528 -1403
Lines 76236 38205 -38031
Branches 8568 0 -8568
===========================================
- Hits 46114 31959 -14155
+ Misses 28017 6246 -21771
+ Partials 2105 0 -2105
| Flag | Coverage Δ | |
|---|---|---|
| hive | ∅ <ø> (∅) |
|
| javascript | ? |
|
| postgres | ∅ <ø> (?) |
|
| presto | ∅ <ø> (∅) |
|
| python | ∅ <ø> (∅) |
|
| sqlite | ∅ <ø> (?) |
|
| unit | ∅ <ø> (∅) |
Flags with carried forward coverage won't be shown. Click here to find out more.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
- :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
Associated issue is marked fixed, closing this one but thanks!