MCPcopy Create free account
hub / github.com/GongShichen/LuminaCode / DrainPendingNotifications

Method DrainPendingNotifications

agent/task_runtime.go:582–592  ·  view source on GitHub ↗
(scopeID string)

Source from the content-addressed store, hash-verified

580}
581
582func (rt *AgentTaskRuntime) DrainPendingNotifications(scopeID string) []map[string]any {
583 rt.mu.Lock()
584 defer rt.mu.Unlock()
585 notifications := rt.notifications[scopeID]
586 rt.notifications[scopeID] = nil
587 out := make([]map[string]any, 0, len(notifications))
588 for _, notification := range notifications {
589 out = append(out, notification.ToMessage())
590 }
591 return out
592}
593
594func (rt *AgentTaskRuntime) consumeMatchingNotifications(scopeID string, taskIDs []string) {
595 rt.mu.Lock()

Calls 1

ToMessageMethod · 0.80