c62d8bc275fb8bc4e5a8d007dae440617924998a
Three bugs in registerChild caused multi-counted outflow in _updatePredictedVolume: 1. machinegroup registered twice (line 66 + line 70 both called _registerPredictedFlowChild). Fixed: only register in the machinegroup branch. 2. Individual machines registered alongside their machinegroup parent. Each pump's predicted flow is already included in MGC's aggregated total — subscribing to both triple-counts. Fixed: only register individual machines when no machinegroup is present (direct-wired pumps without MGC). 3. _registerPredictedFlowChild subscribed to BOTH flow.predicted.downstream AND flow.predicted.atequipment events. These carry the same total flow on two event names — the handler wrote the value twice per tick. Fixed: subscribe to ONE event per child (downstream for outflow, upstream for inflow). These are generalizable patterns: - When a group aggregator exists, subscribe to IT, not its children. - One event per measurement type per child — pick the most specific. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
rotating machine
Description
Languages
JavaScript
77.8%
HTML
22.2%