Problem/Motivation
@phenaproxima and I found this while working on #3605554: Translations are never loaded or downloaded for a custom profile. Drupal core's version on the main branch is 12.0-dev. In install.core.inc Drupal attempts to download https://ftp.drupal.org/files/translations/all/drupal/drupal-12.0-dev.de.po (as an example in German) which falls back / gets redirected on the server side to https://ftp.drupal.org/files/translations/all/drupal/drupal-12.x.de.po. But that does not exist or work with fallbacks until the first alpha release of Drupal 12 is tagged. Localize does not know a "12 branch" exists for Drupal until that happens.
Steps to reproduce
Proposed resolution
To make foreign language install work on 'main' we would either need a core built-in fallback mechanism or a server side fallback mechanism. Given the other fallbacks are implemented on the server side, we propose to implement this too there. See comment #3 for proposed resolution.
Remaining tasks
User interface changes
Introduced terminology
API changes
Data model changes
Release notes snippet
Issue fork drupal-3605895
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
gábor hojtsy@Berdir pointed me to #3594389: Remove unecessary core dev version replacement in locale project info which already deals with the
-devremoval not being needed. Then it is a lack of fallback that remains. @Berdir also suggested the fallback happens on ftp.drupal.org which also makes sense. Will need to rewrite this issue and move this to the infra queue then :)Comment #3
alexpottThe current nginx rules are:
Thanks @drumm for providing them.
I propose that we update them to support getting the previous major version for Drupal core. I considered generalising this for all contrib but it's harder to make assurances about contrib major versions and it does not have as dramatic an impact as core.
LLM disclaimer: I worked with an LLM to update the ruleset to support this new fallback behaviour.
In order to test this we need to confirm that:
https://ftp.drupal.org/files/translations/all/drupal/drupal-12.0-dev.fr.pofalls back tohttps://ftp.drupal.org/files/translations/all/drupal/drupal-12.x.fr.poand thenhttps://ftp.drupal.org/files/translations/all/drupal/drupal-11.x.fr.poand successfully downloads a file.https://ftp.drupal.org/files/translations/all/drupal/drupal-11.4-dev.fr.pofalls back tohttps://ftp.drupal.org/files/translations/all/drupal/drupal-11.x.fr.po(current behaviour)https://ftp.drupal.org/files/translations/all/drupal/drupal-13.0-dev.fr.pofalls back tohttps://ftp.drupal.org/files/translations/all/drupal/drupal-13.x.fr.poand thenhttps://ftp.drupal.org/files/translations/all/drupal/drupal-12.x.fr.poand thenhttps://ftp.drupal.org/files/translations/all/drupal/drupal-11.x.fr.poand successfully downloads a file.https://ftp.drupal.org/files/translations/all/drupal/drupal-25.0-dev.fr.poshould 404https://ftp.drupal.org/files/translations/all/drupal/drupal-13.0-dev.xxxxx.pofalls back tohttps://ftp.drupal.org/files/translations/all/drupal/drupal-13.x.xxxxx.poand thenhttps://ftp.drupal.org/files/translations/all/drupal/drupal-12.x.xxxxx.poand thenhttps://ftp.drupal.org/files/translations/all/drupal/drupal-11.x.xxxxx.poand then 404s.Comment #4
alexpottMoving to the localize.drupal.org project as this fix now involves server config for it.
Comment #5
alexpottAccording to @drumm this can be implemented once localize.drupal.org has moved to AWS which will hopefully happen in the next couple of weeks.
Comment #6
gábor hojtsyMaking it clear this is about Drupal core and under what condition in the title. Also updated issue summary.