Use Django language codes for project languages#12895
Draft
ericholscher wants to merge 3 commits intomainfrom
Draft
Use Django language codes for project languages#12895ericholscher wants to merge 3 commits intomainfrom
ericholscher wants to merge 3 commits intomainfrom
Conversation
Apply ruff format to constants.py and migration 0160. Fix the test_translation_zh_deprecated_code_serving test to use "zh-hans" (the valid Django code) as the project language and verify that accessing the deprecated "/zh/" URL correctly redirects to "/zh-hans/".
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
LANGUAGESProjectandHistoricalProjectrows before changing schema choicesCloses #4411.
Details
0159_migrate_language_codes_to_djangois aSafe.before_deploy()data migration0160_alter_historicalproject_language_and_moreis aSafe.after_deploy()schema migrationpt_BR,zh_CN, and barezhcontinue to resolve and redirect to canonical Django codesTesting
DJANGO_SETTINGS_MODULE=readthedocs.settings.proxito.test /Users/eric/projects/readthedocs.org/.venv/bin/pytest --reuse-db readthedocs/proxito/tests/test_full.py -k 'old_language_code or renamed_old_language_code or sitemap_xml'DJANGO_SETTINGS_MODULE=readthedocs.settings.test /Users/eric/projects/readthedocs.org/.venv/bin/pytest --reuse-db readthedocs/projects/tests/test_build_tasks.py -k 'sphinx_normalized_language or sphinx_normalized_script_language'DJANGO_SETTINGS_MODULE=readthedocs.settings.test /Users/eric/projects/readthedocs.org/.venv/bin/python manage.py makemigrations projects --check --dry-runNotes
makemigrations --check --dry-runstill reports an unrelated pending migration inreadthedocs-ext/donate; this branch does not modify that app.