Repository navigation
feat: use Unraid global temperature thresholds for disk + CPU coloring (0.1.40-beta9) - #208
Merged
Merged
Conversation
…eta9)
Unraid stores global temperature thresholds in dynamix display settings
(display.hot/max for disks, display.warning/critical for CPU). These were
ignored: disk colors used hardcoded 42/50, causing a 52 °C disk with
global crit=60 to show Danger. CPU temp card used sensor-derived flags only.
Changes:
- schema: add `display: InfoDisplay` to Query; vendor `InfoDisplay` type
- queries: add `GetDisplay { display { hot max warning critical } }`
- Models: add `DisplayThresholds`; replace `Disk.tempLevel()` with
`Disk.tempLevel(globalWarnC, globalCritC)` using independent coalescing
(per-disk ?: global ?: hardcoded) — removes beta8 "if-either-set" rule
- Mapper: `GetDisplayQuery.Data.toDisplayThresholds()` extension
- Repository: `displayStream()` at POLL_INFO_MS (60 s)
- ViewModel: `displayState` + `displayThresholds` (nullable unwrap)
gated on overviewOr(Array) — same pattern as dockerLiveStats
- ArrayTab: thread globalDiskWarnC/globalDiskCritC to DiskTile/DiskCard
- OverviewTab: CPU card accent prefers cpuWarnC/cpuCritC from display;
falls back to sensor flags when display poll not yet loaded
- MainScreen: collect displayThresholds, pass to both tabs
- Tests: DiskTempLevelTest updated to new signature + coalescing semantics;
new DisplayThresholdsMappingTest for mapper correctness
- docs: ADR-0045 updated with beta9 precedence rule
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ontent OverviewTab received the threshold params but never forwarded them to OverviewContent (call-site was missing the args) and OverviewContent had no matching parameters in its signature, so the threshold logic at lines 306-309 always resolved to the fallback path. Both gaps are fixed. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.
Per-disk temperature thresholds are null on real servers; the real thresholds live in the dynamix display settings (
display { hot max warning critical }, live-verified hot=55/max=60 for disks, warning=85/critical=95 for CPU).Disk temp coloring now coalesces per-disk → global(hot/max) → hardcoded(42/50), fixing false alarms (a 52° disk wrongly showed danger under the old hardcoded 50, now Normal under the user's max=60); the CPU temperature card accent now uses the global warning/critical.
This supersedes the beta8 per-disk "no-mixing" rule (ADR-0045 updated). Builds on the 0.1.40 cycle.
🤖 Generated with Claude Code