docs: check off set_model_power gap in PID design backlog
Already fixed in 2f2067d (no-op stub on TempControllerBase, 2026-06-25)
but the TODO entry was never marked done.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F4oEE99rkKVU8L8tkzXWdG
This commit is contained in:
+10
-10
@@ -44,16 +44,16 @@ git history for `temp_controller.py`/`temp_controller_smith.py`).
|
||||
the two-model Smith correction itself still have no dedicated
|
||||
coverage. This drives a physical heater — worth extending.
|
||||
|
||||
- [ ] **`set_model_power` isn't defined on every controller, but
|
||||
`brewpi.py` wires it unconditionally.** `brewpi.py` always does
|
||||
`heater.set_on_changed("power_set", tc.set_model_power)` regardless
|
||||
of `Controller.pid_type`. Only `temp_controller_smith.py` (the Smith
|
||||
predictor) defines `set_model_power`; `temp_controller.py` (`"Normal"`)
|
||||
does not, so starting the server with `"pid_type": "Normal"` crashes
|
||||
at wiring time with `AttributeError: 'TempController' object has no
|
||||
attribute 'set_model_power'`. Either add a no-op `set_model_power` to
|
||||
`TempControllerBase`, or only wire it when the configured controller
|
||||
actually exposes a model to feed.
|
||||
- [x] **`set_model_power` isn't defined on every controller, but
|
||||
`brewpi.py` wires it unconditionally.** Fixed: `TempControllerBase`
|
||||
now has a no-op `set_model_power`/`set_ambient_temperature`/
|
||||
`set_model_plant_params` (`temp_controller_base.py:83-90`), so
|
||||
`brewpi.py`'s unconditional `heater.set_on_changed("power_set",
|
||||
tc.set_model_power)` no longer crashes for `"pid_type": "Normal"` -
|
||||
`temp_controller_smith.py` still overrides `set_model_power` to
|
||||
actually feed its internal model. The redundant `hasattr()` guards
|
||||
at both call sites (`brewpi.py`, `components/sud_forecast.py`) were
|
||||
removed along with it.
|
||||
|
||||
- [ ] **Config access is unchecked `dict[key]` everywhere.**
|
||||
`params['Hold']`, `params['Td']`, etc., throughout, with no schema
|
||||
|
||||
Reference in New Issue
Block a user