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 stuck searching for sensor but G7 app is getting results #2286
I’ve had two related issues and I’m not sure if they are the same or just similar.
The first issue I had on 1/29 and is that I had walked away from my phone for 30m. When I came back the CGM was understandably behind on readings. The Dexcom connected back by itself within a few minutes. Loop told me it was searching for sensor for hours though. During this outage I tried
keeping the phone very close, in direct line of sight, to the sensor
rebooting the phone
clearing out all the old Dexcom Bluetooth pairs
deleting the CGM configuration and re adding it
None of those fixed it so I put it down for a couple hours and noticed it had reconnected.
The second issue occurred on 1/30 and is still unresolved. Loop notified me it has not been looping for a while. Loop thinks Dexcom is searching for sensor but Dexcom is giving me current readings
I have been experiencing the same problems for roughly the same duration. I have done 1 sensor change and it still seems to occur on the new sensor as well.
I have had to delete the cgm in Loop and then re add to consistently get it to come back though it may take a few tries.
It will also come back on its own sometimes but no idea why.
Sometimes I notice that after the loop has the problem that Dexcom G7 app will disconnect too . No consistent occurrences though.
My specs are the same with the exception of the iPhone which is a 12.
This is also happening for me. It never happened before I updated to ios 18 on my iphone. For over a year with the same phone it never happened and about 2 weeks after I updated to ios18 is started happening. Loop loses the connection to the sensor but the G7 app shows the readings fine. On rare occasions the G7 app also loses connection but more often it is just loop. I also noticed that when I use my Apple Maps application and specifically for directions it causes loop to disconnect from the sensor. I went 1 week without using Apple Maps directions and did not lose connection. Used Apple Maps once and hours later Loop lost connection to sensor. Typically I have to delete the connection from the G7, make a new connection, close all apps, restart phone and open G7app... wait for connection and then open Loop.
Spent some time looking at this today trying to figure out what’s happening.
I caught a failure happening live. The G7 app had exited but it did get a reading again after reopening and waiting <5min
Loop readings stopped right at the time where the g7 app had its last datapoint so presumably there is some kind of correlation.
The loop device communication log ends here. It’s not had another log event published for over 30m since this. It seems like it thinks the sensor has ended and is scanning for a new one but nothing is happening
So it looks like what might be happening is the sensor is getting connected and disconnected before auth can happen. This would make sense why the Dexcom app also sees the error at this time.
I haven’t figured out yet is what is going on for the next hour while loop is allegedly scanning but Dexcom has recovered. I need to read more about how the messages are structured. I suspect there is something about the message structure where loop having forgotten the sensor has it ignoring messages with readings while it waits for a new message that allows it to reestablish.
It looks like the g7 plugin has debug log events published throughout it that would be really helpful. I do not know how to enable debug logging though.
This does not fix all loss of G7 readings but improves the situation significantly for people who were having the problem and have implemented the customization.
The debug log output you noted is only seen when connected to Xcode.
Activity
JonathonMcIntyre commentedon Feb 7, 2025
I have been experiencing the same problems for roughly the same duration. I have done 1 sensor change and it still seems to occur on the new sensor as well.
I have had to delete the cgm in Loop and then re add to consistently get it to come back though it may take a few tries.
It will also come back on its own sometimes but no idea why.
Sometimes I notice that after the loop has the problem that Dexcom G7 app will disconnect too . No consistent occurrences though.
My specs are the same with the exception of the iPhone which is a 12.
braverymole commentedon Feb 12, 2025
I think I am having the same problem with my daughters loop app. Loop loses sensor but g7 app connected fine.
Quandazo commentedon Feb 13, 2025
This is also happening for me. It never happened before I updated to ios 18 on my iphone. For over a year with the same phone it never happened and about 2 weeks after I updated to ios18 is started happening. Loop loses the connection to the sensor but the G7 app shows the readings fine. On rare occasions the G7 app also loses connection but more often it is just loop. I also noticed that when I use my Apple Maps application and specifically for directions it causes loop to disconnect from the sensor. I went 1 week without using Apple Maps directions and did not lose connection. Used Apple Maps once and hours later Loop lost connection to sensor. Typically I have to delete the connection from the G7, make a new connection, close all apps, restart phone and open G7app... wait for connection and then open Loop.
ssabo commentedon Mar 10, 2025
Spent some time looking at this today trying to figure out what’s happening.
I caught a failure happening live. The G7 app had exited but it did get a reading again after reopening and waiting <5min
Loop readings stopped right at the time where the g7 app had its last datapoint so presumably there is some kind of correlation.
The loop device communication log ends here. It’s not had another log event published for over 30m since this. It seems like it thinks the sensor has ended and is scanning for a new one but nothing is happening
ssabo commentedon Mar 10, 2025
Recovery message. Looks like there is no logging happening between failure and recovery right now for the G7 plugin
ssabo commentedon Mar 10, 2025
So it looks like what might be happening is the sensor is getting connected and disconnected before auth can happen. This would make sense why the Dexcom app also sees the error at this time.
https://github.com/LoopKit/G7SensorKit/blob/2be3eb29b0a18aa89f8b60281341e46e07d024e5/G7SensorKit/G7CGMManager/G7Sensor.swift#L193
I haven’t figured out yet is what is going on for the next hour while loop is allegedly scanning but Dexcom has recovered. I need to read more about how the messages are structured. I suspect there is something about the message structure where loop having forgotten the sensor has it ignoring messages with readings while it waits for a new message that allows it to reestablish.
ssabo commentedon Mar 10, 2025
It looks like the g7 plugin has debug log events published throughout it that would be really helpful. I do not know how to enable debug logging though.
marionbarker commentedon Mar 10, 2025
Have you been following the conversation on zulipchat:
A possible improvement has been proposed and is available as a customization.
This does not fix all loss of G7 readings but improves the situation significantly for people who were having the problem and have implemented the customization.
The debug log output you noted is only seen when connected to Xcode.
ssabo commentedon Mar 10, 2025
@marionbarker i had not! Thank you for pointing me to that. I’m not on Zulip yet but that patch looks like it addresses what I’m experiencing.
I’ll join zulip and catch up on the conversation and try running the customization next.
timd24 commentedon Mar 17, 2025
Yes, I have the same issue. I have been restarting my phone or deleting the sensor to clear the error for now.
marionbarker commentedon Mar 19, 2025
This is a real Issue and is under investigation. But we only want one Issue to track.
Closing this Issue and keeping #2265 open.