Skip to content

Clean up localization review follow-up#26

Merged
next-devin merged 1 commit into
mainfrom
codex/spark-localization-review-cleanup
Jun 21, 2026
Merged

Clean up localization review follow-up#26
next-devin merged 1 commit into
mainfrom
codex/spark-localization-review-cleanup

Conversation

@next-devin

Copy link
Copy Markdown
Contributor

Summary

  • collect localized default assignments across all templates before matching setting fallbacks
  • remove the unused homepage.placeholder.promo_banner locale key from every locale

Validation

  • python3 -m unittest discover -s tests
  • jq empty configs/settings_data.json configs/settings_schema.json locales/*.json
  • git diff --check

@kilo-code-bot

kilo-code-bot Bot commented Jun 21, 2026

Copy link
Copy Markdown

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Overview

Severity Count
CRITICAL 0
WARNING 0
SUGGESTION 0

This PR makes two clean, well-scoped changes:

  1. Locale cleanup (12 files): Removes the unused homepage.placeholder.promo_banner translation key from every locale. The key is not referenced anywhere in templates/, partials/, layouts/, configs/, or assets/, so removal is safe. The companion homepage.heading.promo_banner and homepage.cta_text.promo_banner keys remain because partials/section_promo_banner.html:3,8,14 still uses them via the {% t ... as default_promo_banner_heading %} pattern. All 12 locales are kept in sync with en.default.json, which the existing test_locale_files_keep_the_same_key_shape contract enforces.

  2. Test fix in tests/test_localization_contracts.py:77-91: The refactor lifts localized_default_vars collection out of the per-file inner loop so that {% t "..." as default_xxx %} assignments defined in one template are visible to settings.xxx|default:default_xxx consumers in another template. Previously the set was reset for each file, which would miss cross-file references. The fix is correct: template_paths() is a generator function called fresh each loop, so re-iteration is safe. This makes test_localized_default_override_settings_match_template_usage (line 124) catch missing entries in LOCALIZED_DEFAULT_OVERRIDE_SETTINGS more accurately.

Files Reviewed (13 files)
  • locales/de.json
  • locales/en.default.json
  • locales/es.json
  • locales/fi.json
  • locales/fr.json
  • locales/it.json
  • locales/nl.json
  • locales/no.json
  • locales/pt.json
  • locales/sv.json
  • locales/th.json
  • tests/test_localization_contracts.py

Reviewed by minimax-m3 · Input: 45.7K · Output: 2.2K · Cached: 140.8K

@next-devin next-devin merged commit eb9189f into main Jun 21, 2026
2 checks passed
@next-devin next-devin deleted the codex/spark-localization-review-cleanup branch June 21, 2026 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant