fix(football-scoreboard): stop scroll-card show_date/show_time blanking the full-screen scorebug - #342
Merged
Merged
Conversation
…ng the full-screen scorebug show_date/show_time predate the full-screen (switch mode) display reading the scroll_card block: they governed only the scroll and Vegas cards, so a config that had turned them off there — set back when that was all they did — started silently blanking the stacked date and time in the middle of the switch-mode upcoming scorebug once the block was wired through. With switch_upcoming_center defaulting to date_time, both lines came back empty and the middle drew nothing at all. The full-screen display now has its own switch_show_date and switch_show_time, both defaulting to true — the same back-compat rule that gave it switch_upcoming_center and switch_date_format, because "leave it alone when unset" is not observable once the core has merged schema defaults in. The scroll and Vegas cards keep following show_date/show_time exactly as before, and a regression check pins that the shared keys no longer reach this display. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SWe8ZdMQ1itP25XyzrwnhW
Contributor
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Up to standards ✅🟢 Issues
|
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.
What broke
On a switch-mode display whose config had
scroll_card.show_date/show_timeset tofalse, the full-screen upcoming scorebug drew nothing in its middle:switch_upcoming_centerdefaults todate_time, and both of its lines came back blanked. Observed live on a 256x64 device (2.29.0) — upcoming games rotated with logos and the "Next" header but no date or time.Why
show_date/show_timepredate the full-screen display reading thescroll_cardblock: they governed only the scroll and Vegas cards, so configs turned them off back when that was all they did. When the block was wired through to the switch scorebug, those old settings started silently blanking a display that has always drawn both lines — exactly the regressionswitch_upcoming_center/switch_date_formatwere introduced to prevent, and for the same reason "unset" is unobservable: the core merges schema defaults into the config on every load.Fix
_upcoming_date_and_time_text()now readsswitch_show_date/switch_show_time, both defaulting totrue, so every existing panel renders what it rendered before.config_schema.jsonunder the scroll_card block, alongside the otherswitch_*overrides.show_date/show_timeexactly as before (game_renderer.py untouched).Tests
test_switch_upcoming_center.pyupdated: the show/hide checks exercise the new keys, plus a new regression pin that a render withshow_date: false, show_time: falseis byte-identical to the default render.test_scroll_mode.pyandtest_config_reload.pypass.test_adaptive_layout_mode.pyhas 12 pre-existing failures identical on pristinemain(local font-environment related), none introduced here.🤖 Generated with Claude Code
https://claude.ai/code/session_01SWe8ZdMQ1itP25XyzrwnhW