Skip to content

3.7.0

Choose a tag to compare

@jboulton jboulton released this 11 Oct 08:46
· 59 commits to master since this release

Breaking changes

  • EG800Q and Lte767xConnection are no longer exported from dashio while the modem connections are reworked. Import them from their modules, e.g. from dashio import lte_767x_connection.
  • DashConnection connects from its connection thread, a moment after it is created, instead of in its constructor. Add your devices straight after creating the connection, as the examples do.
  • Receive callbacks that return a string now send it to the Dash app as a reply. Callbacks that return anything else behave as before.

New

  • DashConnection tells the Dash app when devices go online and offline:
    • ONLINE is sent for each device when the connection is made, and for a device added later.
    • close() sends OFFLINE for each device before disconnecting.
    • If the connection is lost, e.g. the program stops unexpectedly, the Dash server publishes OFFLINE for the first device on the connection (its MQTT Last Will). The new offline_delay parameter (default 10 seconds) delays it, so reconnecting within that time cancels it. An MQTT connection has a single will, so it only covers the first device.

Fixes

  • Devices answer the Dash app's history requests again. Since January 2023 a device never replied to the app's TimeGraph, EventLog or Map history requests, so the app only had the data it had received live, unless the data was stored on the Dash server. Replies from receive callbacks were also lost.
  • Map history no longer crashes, a bad request time is ignored, and each track keeps its track ID.
  • EventLog history sends nothing when there are no events to send.

See Documentation.md for DashConnection.