Before submitting
Firmware Version
iOS 2.7.6 (but probably started earlier)
What did you do?
I noticed my node list was never shrinking. I searched the codebase to find what calls clearStaleNodes (defined in UpdateCoreData). Found no call sites!
Expected Behavior
Expected it would be called somewhere 😓
Current Behavior
No response
Participation
Additional comments
It looks like the maintenanceTimer which called clearStaleNodes was removed when BLEManager was removed in #1341 (2025-08-27):
https://github.com/meshtastic/Meshtastic-Apple/pull/1341/files#diff-a4bfb0bac704fbf4f688a8a51b3f99d1d786aa043b5b6d0507605cdff1a51ae4L90-L97
// Run clearStaleNodes every hour
maintenanceTimer = Timer.scheduledTimer(withTimeInterval: 3600, repeats: true, block: { _ in
let result = clearStaleNodes(nodeExpireDays: Int(self.purgeStaleNodeDays), context: self.context)
// If you are connected and the clear worked, pull nodes back from the node in case we have deleted anything from that app that is in the device nodedb
if result && self.isSubscribed {
self.sendWantConfig()
}
})
I'm not sure where it should live now, but probably somewhere? I'd happy to try making a PR, but would want @garthvh 's advice on where it would be best for the maintenanceTimer to live now that has easy access to all the relevant context?
Code of Conduct
Before submitting
Firmware Version
iOS 2.7.6 (but probably started earlier)
What did you do?
I noticed my node list was never shrinking. I searched the codebase to find what calls
clearStaleNodes(defined inUpdateCoreData). Found no call sites!Expected Behavior
Expected it would be called somewhere 😓
Current Behavior
No response
Participation
Additional comments
It looks like the
maintenanceTimerwhich calledclearStaleNodeswas removed whenBLEManagerwas removed in #1341 (2025-08-27):https://github.com/meshtastic/Meshtastic-Apple/pull/1341/files#diff-a4bfb0bac704fbf4f688a8a51b3f99d1d786aa043b5b6d0507605cdff1a51ae4L90-L97
I'm not sure where it should live now, but probably somewhere? I'd happy to try making a PR, but would want @garthvh 's advice on where it would be best for the
maintenanceTimerto live now that has easy access to all the relevant context?Code of Conduct