Repository navigation
Fix Spanish locale cookie fallback, dynamic tooltips and browser smoke false positives - #15
Merged
Merged
Conversation
…ge is blocked (RED)
…ecuted script (RED)
…ribute coverage (RED)
…mically generated pad tooltips
Reviewer's GuideThe PR hardens English/Spanish locale resolution across client, installer, and server paths, adds the missing generated pad tooltip translations, and replaces browser smoke false-positive detection with strict rendered-output and exact-cookie validation backed by regression tests. Sequence diagram for locale fallback on browser reloadsequenceDiagram
participant Browser
participant LocalStorage
participant Cookie
participant UI
Browser->>LocalStorage: getItem(beatos_locale)
alt explicit localStorage preference exists
LocalStorage-->>Browser: en or es
else localStorage missing or unavailable
Browser->>Cookie: document.cookie
Cookie-->>Browser: exact beatos_locale=en or beatos_locale=es
end
Browser->>UI: apply resolved locale
UI-->>Browser: render translated labels and tooltips
Flow diagram for installer and server language fallbackflowchart TD
A[Installer language input] --> B[get_language]
B --> C{Normalized value is es}
C -->|yes| D[Use es]
C -->|no| E[Use en]
F[BEATOS_LANG] --> G{Empty or unset}
G -->|yes| H[Use en for translate_text]
G -->|no| I[Use configured language]
D --> J[Translated installer or server output]
E --> J
H --> J
I --> J
Flow diagram for browser smoke validationflowchart TD
A[Run browser smoke] --> B[Execute page interaction]
B --> C{Rendered output node exists}
C -->|no| D[Fail smoke test]
C -->|yes| E{Exact beatos_locale cookie value}
E -->|no| D
E -->|yes| F[Pass smoke test]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
…tle and ARIA attributes
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.
Root cause and scope
Historic October 30 test failures in
feat/english-default-i18n-release-readinesswere on intermediate commits; merged PR #9 and currentmainCI already passed. Sourcery found two legitimate edge cases. EmptyBEATOS_LANGwas fixed inmain, but localStorage-disabled sessions still reset explicit Spanish to English because the browser ignored the storedbeatos_localecookie on reload.Fixes
beatos_locale=en|escookie when localStorage is missing or unavailable; explicit localStorage preference has precedence. Do not match suffixes (es-MX) or similarly named cookies.BEATOS_LANGdoesn't suppress console translations.Asignar al Pad Objetivo Activo,Vaciar Pad 1) and expand i18n guard coverage.Release boundary: this PR changes no hardware exporters, does not bump or republish the v3.8.0 stable asset, and does not certify Pocket Operator physical restore. PR #14 remains separate and draft pending device validation.
Summary by Sourcery
Harden locale fallback and browser smoke validation while completing English translations for generated interface tooltips.
Bug Fixes:
Tests:
Chores: