Repository navigation
Fixed
- Reconnect to the Obico server after a connection dies silently. If the network path to the server drops without a FIN or RST reaching the printer — a firewall reboot or a NAT state flush — the plugin sent no websocket pings and had no TCP keepalive, so its socket kept reporting itself connected, the close handler never ran, and the reconnect loop kept reusing a dead connection. The printer showed as offline until OctoPrint was restarted. The plugin now pings the server every 30s with a 15s timeout, so a dead connection is closed and re-established on its own. Measured detection took 48-90s.
The Obico server has always pinged from its side, which is why the server noticed these dead connections and the plugin did not. This adds the missing half of that pair.
Connections to Janus and the local tunnel are unchanged: they are local, so they cannot go half-open this way, and pings stay off for them.
This is a port of the same fix in moonraker-obico, reported and contributed there by robisonjoel (TheSpaghettiDetective/moonraker-obico#141).
Internal
- New
tests/test_ws_dead_peer.pydrives a real websocket server through a TCP proxy that can silently drop traffic. Thewebsocketspackage it needs is declared as atestextra, so it is not installed on printers.
The release includes 17 passing unit tests against the pinned websocket-client==1.6.1, and the built wheel was verified for version, OctoPrint entry point, and dependency metadata.