MCPcopy Create free account
hub / github.com/github/copilot-sdk / finishCancelled

Method finishCancelled

go/copilot_request_handler.go:689–701  ·  view source on GitHub ↗
(sink *responseSink, exchange *pendingExchange)

Source from the content-addressed store, hash-verified

687}
688
689func (a *copilotRequestAdapter) finishCancelled(sink *responseSink, exchange *pendingExchange) {
690 exchange.mu.Lock()
691 finished := exchange.finished
692 started := exchange.started
693 exchange.mu.Unlock()
694 if finished {
695 return
696 }
697 if !started {
698 _ = sink.start(499, "", http.Header{})
699 }
700 _ = sink.sinkError("Request cancelled by runtime", "cancelled")
701}
702
703func (a *copilotRequestAdapter) removePending(requestID string) {
704 a.mu.Lock()

Callers 1

runHandlerMethod · 0.95

Calls 2

sinkErrorMethod · 0.80
startMethod · 0.45

Tested by

no test coverage detected