Repository navigation
Conversation
The message was an f-string inside gettext, so it was never translatable. Under Python 3.12, Babel also extracts the f-string's inner "value" and "name" literals as a bogus msgid "valuename", which fails check_pot_drift in the 3.12 unit-test job. Also regenerates the catalogs, which were missing apache#44036's reworded connection-move message.
Contributor
|
Bito Review Skipped - Source Branch Not Found |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #44548 +/- ##
===========================================
+ Coverage 66.20% 80.91% +14.71%
===========================================
Files 2948 2948
Lines 177295 177293 -2
Branches 41089 41087 -2
===========================================
+ Hits 117376 143465 +26089
+ Misses 57416 31122 -26294
- Partials 2503 2706 +203
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
SUMMARY
The "chart referenced by annotation layer was not found" error in
superset/common/query_context_processor.pywas an f-string insidegettext, so it has never been translatable. It also breaks the pot drift check added in #44467 on the Python 3.12 unit-test job: with 3.12's f-string tokenization (PEP 701), Babel picks up the literal"value"and"name"dict keys inside the f-string's replacement fields and extracts them as a bogus msgidvaluename. Python 3.11 skips the f-string, so only thenextjob fails.This changes the call to a normal parameterized gettext message and regenerates the catalogs with
scripts/translations/babel_update.sh. The regeneration also picks up the reworded connection-move message from #44036, which merged without a catalog update and makescheck_pot_driftfail on 3.11 as well.TESTING INSTRUCTIONS
python scripts/translations/check_pot_drift.pypasses under Python 3.11.uv run --no-project --python 3.12 --with babel==2.17.0 --with jinja2==3.1.6 -- python scripts/translations/check_pot_drift.py. Before this change it reportsvaluenameas missing.pytest tests/unit_tests/common/ tests/unit_tests/scripts/translations/ADDITIONAL INFORMATION
The same fix is already on the
7.0release branch.