You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Loop can skip/miss Manual Boluses resulting in incorrect IoB #853
I took 5U AT 10:05am manually via audio bolus. The manual bolus shows up in my pump history and Loop sees it in Event History (see pic.) I RARELY bolus this way so I am not sure what the expected behavior is. I would personally expect Loop to see the bolus in history and have it show up as IoB.
I am on 1.9.4dev so I’m feeling this may be related to the “Loop stores insulin in HealthKit” path? Perhaps it’s using HealthKit as the authoritative source and not seeing the Bolus?
It feels like if Loop misses a manual Bolus (perhaps while the bolus is long running?) and then Loop temp basals and records that temp to HealthKit that it won’t look back in Event History and see the previous manual bolus.
UPDATE: I went into HealthKit and manually deleted Insulin Delivery Record’s going back until 10am, then force quit Loop. Loop then recovered and populated IoB correctly. This was an interesting bug/issue as because Loop thought I had no IoB it had Temp Basaled me to 3U/hr which would have been a problem later.
To Reproduce
Guessing here, will try to repro again. Steps to reproduce the behavior:
Enable Loop to log Insulin in HealthKit
Largeish manual bolus
Loop loops and temp basals shortly after bolus.
Loop misses manual loop. Should show manual bolus as IoB but doesn't.
Expected behavior
I'd expect loop to look back n number of events in case it missed a manual bolus, rather than using (?) HealthKit as the authoritative source.
Screenshots
Note the bolus around 10:05am
Bolus recorded here at 10:05am
Bolus missing from HealthKit. Instead a 1.05U basal is present? Then follow up basals.
Note missing basal
Phone
Hardware: iPhone XS Max
OS Version: 12.1.1 (16C50)
Loop Version
Version Number: 1.9.4
Repo: LoopKit/dev
CGM
Device: Dexcom G5
Manager app: Dexcom App
Pump
Manufacturer: Medtronic
Model: 522
Firmware version: 2.4a 1.1 0B 0B
Additional context
I was having a considerable low at the time and Loop had me temped at 0. I was taking the 5U in anticipation of a very large lunch.
I've had no problem in the past with Loop seeing manual boluses (though it can take a little time before it pulls the history and sees the bolus). Curious to see if you can reproduce it; I'll try as well with some manual boluses to see what happens. Was Loop completely successfully (green loop) between when you gave the bolus and when you took the above screenshots?
This fix is in Loop dev now. Please test if you can. The issue happens on x22 medtronic pumps when 1) A (large) bolus is started. 2) A temp basal ends before the bolus finishes. 3) Loop fetches pump history as part of a normal loop before the bolus finishes.
I'm having an issue similar to the one described here. Loop fails to write the Insulin Delivery data to HealthKit, and therefore no bolus is logged. It shows up in Loop, but when I restart the app, all boluses disappear (presumably as Loop reads HealthKit's ID data as blank).
Loop has no issue in reading/writing my carbohydrate data to HealthKit, and repopulating the graph after a restart, so I struggle to understand the exact cause of this issue.
This is even after updating to the newest release, 1.9.4. Any and all help/suggestions is insanely appreciated! Your hard work and dedication to this life-changing project certainly does not go unnoticed.
Wish it had been as simple as that! Thanks for the quick reply.
Figured out that Loop wasn't updating with my pump correctly, and therefore wasn't retrieving the pump data in a timely (enough) manner. As soon as this was resolved, all of my boluses were populated in the health app.
Thank you for getting back to me so quickly! You truly are a God-send for this community. I hope to make some contributions myself, as my familiarity with the project improves (I'm an intermediate developer and graphic artist myself).
Activity
elnjensen commentedon Dec 14, 2018
I've had no problem in the past with Loop seeing manual boluses (though it can take a little time before it pulls the history and sees the bolus). Curious to see if you can reproduce it; I'll try as well with some manual boluses to see what happens. Was Loop completely successfully (green loop) between when you gave the bolus and when you took the above screenshots?
Reproduces and fixes the following:
Reproduces and fixes the following:
HealthKit Sync Fix (#253)
ps2 commentedon Jan 8, 2019
This fix is in Loop dev now. Please test if you can. The issue happens on x22 medtronic pumps when 1) A (large) bolus is started. 2) A temp basal ends before the bolus finishes. 3) Loop fetches pump history as part of a normal loop before the bolus finishes.
shanselman commentedon Jan 8, 2019
Amazing! Glad you found this. It's so awesome to hunt down weird - but significant - bugs like this! THANK YOU! 🥇
fgutteridge commentedon Jan 28, 2019
Hey there, new Looper here.
I'm having an issue similar to the one described here. Loop fails to write the Insulin Delivery data to HealthKit, and therefore no bolus is logged. It shows up in Loop, but when I restart the app, all boluses disappear (presumably as Loop reads HealthKit's ID data as blank).
Loop has no issue in reading/writing my carbohydrate data to HealthKit, and repopulating the graph after a restart, so I struggle to understand the exact cause of this issue.
This is even after updating to the newest release, 1.9.4. Any and all help/suggestions is insanely appreciated! Your hard work and dedication to this life-changing project certainly does not go unnoticed.
ps2 commentedon Jan 28, 2019
@fgutteridge go to settings app -> privacy -> health -> Loop, and make sure Loop has all insulin permissions enabled.
fgutteridge commentedon Jan 28, 2019
Wish it had been as simple as that! Thanks for the quick reply.
Figured out that Loop wasn't updating with my pump correctly, and therefore wasn't retrieving the pump data in a timely (enough) manner. As soon as this was resolved, all of my boluses were populated in the health app.
Thank you for getting back to me so quickly! You truly are a God-send for this community. I hope to make some contributions myself, as my familiarity with the project improves (I'm an intermediate developer and graphic artist myself).
Thanks again. Happy Monday.
Kdisimone commentedon Jan 28, 2019
Sounds like it’s all resolved. Thanks Pete!
[LOOP-5496] updated copy (LoopKit#853)