11 Risks and Technical Debt

This chapter lists known risks and technical debt in the Station’s current architecture. Trade-offs already knowingly accepted when choosing its core technologies are documented as consequences of the corresponding decision instead: STA-001, STA-002 and STA-005, which supersedes STA-003.

  • Working-directory-relative persistence: both the read-only recipe/ingredient/glass data and the read-write ingredient-to-dispenser mapping, glass volumes and fill levels are located relative to the process’s current working directory rather than a fixed, installed location. Starting the Station from an unintended working directory silently changes, or loses access to, its data instead of failing loudly.

  • Fill level while the Station is off: the Station can only correct a fill level from what it last stored. A bottle refilled while the Station is off stays unnoticed until someone corrects its fill level.

  • Load cell drift: a load cell’s reading wanders slowly even with nothing on the scale. Up to about 20 g in an hour has been measured, on an unloaded and uncalibrated cell. A pour lasts seconds and doesn’t notice, but a fill level kept over hours can be that far off. The Station doesn’t compensate for it, and the warning before a drink only leaves a reserve of 20 mL.

  • A false empty followed by a small top-up: the Station takes the top-up for the whole content of the bottle, as it can’t tell this from a real refill. The warning then shows too little until the next refill or the button in the Operator UI.

  • A Pod on another release can look silent: the Station checks the protocol release only after it has decoded the whole DeviceInfoResponse. A release that changes the rest of that message gives a reply that doesn’t decode, and then the Station only logs a hint instead of naming the release. Reading ProtocolVersion from the frame before decoding the rest would close that gap.

  • Simulated hardware ships in the same binary as production: the compile-time switch between simulated and real Pods only changes which code path runs. The simulator code itself is always linked into every build, including the one shipped to a real machine. This has no functional effect today, but the production binary does carry code that never executes on the actual device, and any future change to the simulator must be validated against the production build as well.

  • Single shared executor: every Pod exchange and every UI-triggered action runs on one execution context. A per-exchange timeout bounds any single exchange, but a very slow or misbehaving exchange can still delay unrelated work until its own timeout elapses, since no other Pod or recipe work runs in parallel to it today.

Open Points

  • Running a pump until stopped: cleaning a pump with hot water needs it to run until someone stops it. The protocol only has Dispense, which pours a fixed amount, and the calibration run, which runs for a fixed time. The Operator UI will offer the action per pump. It needs a new protocol message and support in the Pod firmware before it does anything.

  • Running a pump backwards: emptying the tubes needs a pump to run in reverse. Neither the protocol nor the Pod firmware can do this yet. The Operator UI will offer the action per pump, and it stays without effect until both are extended.

  • Restarting a Pod: the protocol has no message that restarts a Pod. The Operator UI will offer a restart per Pod, and it stays without effect until the protocol and the Pod firmware support it.

  • Reconnecting a Pod: discovery only reports a port when it appears, so a Pod whose session ended stays away until it is unplugged. The Operator UI will offer a reconnect per Pod. It needs the Station to end that Pod’s session and open its port again.

  • Show front leak protection: the show front may hold a liquid next to the Raspberry Pi, the display and the power supply (System contract IF-09-R04). How a leak is kept away from them is not designed yet.