Update i18n gem (~> 1.5.3)
|Assignee:||Go MAEDA||% Done:|
#3 Updated by Marius BALTEANU 3 months ago
The test that fails on my local environment is the below one and not the one from r16324.
root@45ec3a6558b0:/work# ruby test/unit/lib/redmine/i18n_test.rb DEPRECATION WARNING: `secrets.secret_token` is deprecated in favor of `secret_key_base` and will be removed in Rails 6.0. (called from <top (required)> at /work/config/environment.rb:14) Run options: --seed 36235 # Running: .........F Failure: Redmine::I18nTest#test_fallback [test/unit/lib/redmine/i18n_test.rb:234]: --- expected +++ actual @@ -1 +1 @@ -"Untranslated string" +"translation missing: fr.untranslated"
#4 Updated by Marius BALTEANU 3 months ago
- File 0001-Updates-i18n-gem-to-1.1.1.patch added
There are multiple changes between 0.7.0 version and 1.1.1.
One reason of the failing test is https://github.com/svenfuchs/i18n/pull/415 which doesn't consider anymore the default locale as fallback locale. Now you need to explicitly define in the config the fallback locales. For example, if we add the line
config.i18n.fallbacks = [:en] to
config/application.rb, the above test will pass, but I don't think that should be the solution because from what I've observed until now, we add the en version of the locale to all locale files (which is healthier from point of view).
Attached the patch that updates the gem version and fixes the failing test. The safest way is to schedule this update for 4.1.0 in order to have time to catch missing translation keys (if exists).
#7 Updated by Marius BALTEANU 10 days ago
- File 0001-Update-i18n-gem-to-1.5.3.patch added
- Assignee deleted (
- Target version changed from Candidate for next major release to 4.1.0
I've attached a new patch with a different fix, but I would like a review on the proposed changes even if all the existing tests pass
In my note 3, I wasn't able to reproduce the failing test because the fallback was not enabled.