Conversation
Co-authored-by: ericholscher <25510+ericholscher@users.noreply.github.com>
Co-authored-by: ericholscher <25510+ericholscher@users.noreply.github.com>
|
@copilot remove all the translated locale files, don't touch the templates. |
Co-authored-by: ericholscher <25510+ericholscher@users.noreply.github.com>
|
@copilot Remove any transifex config and other invoke tasks that update these files as well. |
Co-authored-by: ericholscher <25510+ericholscher@users.noreply.github.com>
Removed |
Co-authored-by: ericholscher <25510+ericholscher@users.noreply.github.com>
|
@copilot dont touch the templates but do change settings, etc. |
Co-authored-by: ericholscher <25510+ericholscher@users.noreply.github.com>
Done. Reverted template changes and disabled i18n in settings instead. Changes in commit 9bd57fe:
Templates now retain their i18n tags, but Django won't process them since |
|
Not sure if this will effect anything (eg. emails? notifications?), but if the dashboard isn't translated, I think this is the right move to rip the infra out. |
|
Removing the translation files seems like the wrong approach here. What we need is to ensure translation source strings are updated from the templates. This hasn't been set up yet and there are likely some extra steps here. Or it might just be a matter of source strings being out of date. But ultimately the source strings should probably still be in the locale files in this repo, I'm guessing. If not, and we translate at ext-theme, we still need these files to enable application translations and translation of source strings in the code here. |
With all non-English locale files removed, disables Django's internationalization system for the dashboard by changing configuration instead of modifying templates.
Changes
Settings (
readthedocs/settings/base.py)USE_I18N = Falseto disable internationalizationLANGUAGEStuple to only Englishdjango.middleware.locale.LocaleMiddlewaredjango.template.context_processors.i18nURLs (
readthedocs/urls.py)/i18n/)Transifex Configuration
.tx/configfor dashboard translationsLocale Files
readthedocs/locale/en/Templates
{% trans %},{% blocktrans %})USE_I18N=FalseRationale
Disabling i18n at the framework level provides several benefits:
The templates remain unchanged with standard Django i18n patterns, but Django won't process them since
USE_I18N=False.Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.