-
Notifications
You must be signed in to change notification settings - Fork 30
Clear Calibrations unless restart specifically requested #188
Description
Lookout does the following logic --> a Sensor Insert, Sensor Start or Sensor Stop will invalidate any BG Checks prior to that event. Only the BG Checks after the most recent of any of those events will be used, and if there are not enough BG Checks to calculate an LSR calibration, it will delete the calibration it has if it had one.
Logger does the following: a Sensor Insert clears the cache. It also means that Logger will only keep the latest calibration record for the first 12 hours (which are usually unstable and not good inputs for LSR). Logger doesn't clear cache for Sensor Start nor Sensor Stop.
and we don't want starts/stops to clear the cache since that would ruin restarts
A separate restart nightscout treatment would help with that
Someone should not have to do extra work to indicate something is not a restart. we should default to the (safer) new-sensor behavior unless someone specifically notes that they're doing a restart
that to me is the strongest reason for needing a separate sensor restart treatment in NS
A Sensor Insert, Sensor Start, and a Sensor Stop will invalidate any BG Checks prior to that event (same as Lookout). Then, if in NS, you add a "restart sensor" treatment type that will Stop/Start the sensor without deleting the calibration cache. Add restart sensor to the Logger command line utilities as well.