fix(schema): correct 5 default mismatches in param_definitions.json#830
Conversation
Five entries in param_definitions.json (GUI hint metadata) disagreed with config_defaults.json (authoritative runtime defaults). Schema defaults dictate initial form values shown to users; mismatches mislead new installations. Source-of-truth (config_defaults.json) unchanged. - historic_days_to_retrieve: 2 → 9 (default_value + Description text) - inverter_ac_output_max: 0 → 5000 - inverter_ac_input_max: 0 → 5000 - load_forecast_method: "typical" → "naive" - ignore_pv_feedback_during_curtailment: input "bool" → "boolean" Findings derived from input-side schema audit cross-checking param_definitions.json against config_defaults.json and utils.treat_runtimeparams. Audit + reproducer: https://github.com/OptimalNothing90/emhass-contributions/blob/master/audits/2026-04-28-param-definitions.md
Reviewer's guide (collapsed on small PRs)Reviewer's GuideAligns five GUI parameter schema defaults and one input type with the actual runtime defaults defined in config_defaults.json, so the web configuration form now reflects the true operational defaults without changing runtime behavior. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #830 +/- ##
=======================================
Coverage 82.46% 82.46%
=======================================
Files 10 10
Lines 5975 5975
=======================================
Hits 4927 4927
Misses 1048 1048 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Hi, |
|
Can do, but this will change code default's as well. For inverter, it seemed kind of philosophical to me, will change it too |
@OptimalNothing90 So it seems that this PR's is updating |
|
@davidusb-geek I checked the code path before flipping. So today there are two effective defaults per param:
That's the inconsistency. Direction matters because flipping changes behavior for Headless users:
The boolean fix ( Two options: A) Treat B) Treat Your call. Either way I'll keep the boolean type fix. |
Summary
Corrects 5 default-value / input-spelling mismatches in
param_definitions.jsonagainstconfig_defaults.json. Source-of-truth(
config_defaults.json) unchanged; only the GUI schema is brought backin line so the web config form shows the actual runtime defaults.
Before / After
Verification
Reproducer script + full audit:
https://github.com/OptimalNothing90/emhass-contributions/blob/master/audits/2026-04-28-param-definitions.md (Section 3)
Re-verified against current
mastertip on 2026-04-30 — all 5 still hold.Notes
the schema-displayed initial form values change.
Summary by Sourcery
Align GUI parameter schema defaults and input types with the canonical runtime configuration defaults for affected parameters.
Bug Fixes: