stability: propagate request context end-to-end #6
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Tool handlers receive a
context.Contextfrom the MCP frame but most operation modules ignore it — they construct a fresh Gitea SDK client (with its own 60s timeout inpkg/gitea/rest.go) and call methods that don't take a context. As a result:operation/operation.go) only stops accepting new connections; in-flight tool calls continueSuggested direction
*Ctxvariants, switch to them and pass the handler'sctxhttp.ClientTransportwith one that watchesctx.Done()and aborts the request