Closed kskandis closed 2 weeks ago
The patch you posted in #265 was not successful with a rPi DASH simulator. I'm going to return to the Issue to post results in comments. I also have some more suggestions from @itsmojo for things to look at which I will also post under the issue. I definitely need and appreciate the help.
This PR resolves this issue by excluding
BolusState.canceling
from sending abolusTrigger.send(false)
to APSManager which would tripper abolusReporter?.removeObserver
.This is because if the
bolusReporter
observer is prematurely removed then the cancel completion will not be observed. APSManager separately observes CancelBolus and then will remove thebolusReporter
so there is no reason to includeBolusState.canceling
in the trigger.I tested this in Mock and Cancel Bolus succeeds. I also commented out
updateStatus()
. Once PR is tested,updateStatus()
func should be removed.