From d4c246fa0c4648add857bea8693b280a616aaeef Mon Sep 17 00:00:00 2001 From: AskaEth Date: Sun, 28 Jun 2026 17:07:24 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E7=A7=BB=E9=99=A4=E6=9C=89=E9=97=AE?= =?UTF-8?q?=E9=A2=98=E7=9A=84runtime.SetFinalizer?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/ai-core/internal/background/thinker.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/backend/ai-core/internal/background/thinker.go b/backend/ai-core/internal/background/thinker.go index c8ed50f..2a2ca3c 100644 --- a/backend/ai-core/internal/background/thinker.go +++ b/backend/ai-core/internal/background/thinker.go @@ -2661,6 +2661,10 @@ func (t *Thinker) muLock() { // muUnlock releases t.mu and clears the tracking. func (t *Thinker) muUnlock() { + held := time.Since(t.muLockedAt) + if held > 5*time.Second { + log.Printf("[debug] muUnlock: lock held for %v by %s", held.Round(time.Millisecond), t.muLockedBy) + } t.muLockedBy = "" t.mu.Unlock() }