Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Basal Incorrectly showing as 0 #8238

Open
motinis opened this issue Mar 11, 2024 · 2 comments
Open

Basal Incorrectly showing as 0 #8238

motinis opened this issue Mar 11, 2024 · 2 comments

Comments

@motinis
Copy link

motinis commented Mar 11, 2024

This was seen using Loop.

Link to relevant Zulip message showing the issue:
https://loop.zulipchat.com/#narrow/stream/144182-development/topic/Graph.2Fprediction.20discrepancy.3F/near/423206819

Seen with 0 basals, may occur with others as well (not known).
When using Loop in auto-bolus mode, it will set a 0 temp basal. When Loop determines it is no longer needed, the temp basal is cancelled. Nightscout Basal pill (and basal display icicle) continues to display 0, while Loop pill states correctly that the temp basal was cancelled.

See this image (copied out from the above Zulip thread):
image

This has been seen on Nightscout 15.0.2.

Update March 14, 2024:
Also have seen the other way around, where Loop enacted a 0 basal but NS is display a non-zero basal. Likely to be caused by the same underlying issue.

IMG_8847

@motinis
Copy link
Author

motinis commented Mar 11, 2024

As a note in terms of possible (?) fixes (copied out from Zulip thread):

This looks to me to be caused at this location in NS, where the prev. temp basal is used; my guess is that it's not properly cleared out when loop cancels things. Also note that the data there is sticky for the whole life of the temp-basal, the data that gets displayed for the temp-basal (see this function) uses a cache with a TTL, but the underlying data it will pull in after the TTL may not be refreshed. I'm really not an NS expert here; but possible fixes to me:

  • Replace that prevBasalTreatment variable with an entry in the cache with a TTL
  • Check the path upon which Loop updates the data; it should most likely result in a call to profile.clear() or something that will force an update. Maybe this is in profile.updateTreatments I think that prevBasalTreatment should be cleared

These aren't mutually exclusive.

@Heiner1
Copy link

Heiner1 commented Mar 25, 2024

Same to me:
ZeroTemp won't be displayed, looks like "pump disconnected". But at reports site it's shown correctly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants