PolinaFam opened a new pull request, #34049: URL: https://github.com/apache/superset/pull/34049
### SUMMARY **Issue Description** The problem occurs when the default language is not English. Switching the language to English does not fully apply, leaving some menu elements in the previous language. All untranslated strings are located in `superset/initialization/__init__.py`. **Solution** Replace all instances of gettext with lazy_gettext in `superset/initialization/__init__.py`. This ensures proper language switching, and all elements update correctly when changing languages. ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF   ### TESTING INSTRUCTIONS 1. Add next lines to config file: ```py BABEL_DEFAULT_LOCALE` = "ru" LANGUAGES = { "ru": {"flag": "ru", "name": "Русский"}, "en": {"flag": "us", "name": "English"} } ``` 2. Start the application. 3. Switch the interface language to English. 4. 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](https://github.com/apache/superset/issues/13351)) - [ ] 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 -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
