MCPcopy Create free account
hub / github.com/Botloader/botloader / handle_tick

Method handle_tick

components/scheduler/src/command_manager.rs:144–157  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

142 }
143
144 async fn handle_tick(&mut self) {
145 let old_list = std::mem::take(&mut self.pending_checks);
146
147 for item in old_list {
148 if item.started.elapsed() > Duration::from_secs(10) {
149 if self.process_item(&item).await.is_err() {
150 // add back to queue if processing failed
151 self.pending_checks.push(item);
152 }
153 } else {
154 self.pending_checks.push(item);
155 }
156 }
157 }
158
159 async fn process_item(&mut self, item: &PendingCheckGroup) -> Result<(), ()> {
160 // TODO: only do this when they have actually changed

Callers

nothing calls this directly

Calls 1

process_itemMethod · 0.80

Tested by

no test coverage detected