Kimi K3.1 Pro · Balanced

feature-localization-fallbacks-server-side-discourse-cursor

Discourse · Ruby · S · 30–99 lines · 6 files

The normal review, with one generalist agent. Judge: Claude Haiku 5.5.

Gold bugs found
2 of 2
Comments published
2
Comments matching a bug
2
Comments not matching
0
Cost of this PR
$0.514

Published comments (2)

mediumbugapp/controllers/application_controller.rb:159

Controller-only fallback preloading misses background job translations — Fresh workers can return missing translations when `I18n.translate` tries an unloaded default or English fallback, even though a translation is available. Move `I18n.fallbacks.ensure_loaded!` into the shared locale path, or also call it from `Jobs::Base` and other non-controller entry points.

mediumbugconfig/initializers/i18n.rb:17

Fallback cache key omits the site default locale — Include the default locale or full fallback order in that key, or invalidate the `I18n` cache when the default changes.

Gold bugs found (2)

mediumFallback locale catalogs are only loaded in the controller's set_locale filter, while translate loads just the current locale, so translations outside requests (jobs, mailers) cannot fall back to the site default or English.
mediumThe translation cache key does not include the site or its default locale, but fallback results now depend on SiteSetting.default_locale, so multisite processes or a changed default locale serve stale fallback translations.

Gold bugs missed (0)

None.