MCPcopy Index your code
hub / github.com/anomalyco/opencode / close

Function close

packages/opencode/src/cli/cmd/run/runtime.queue.ts:100–111  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

98 }
99
100 const close = () => {
101 if (state.closed) {
102 return
103 }
104
105 state.closed = true
106 state.queue.length = 0
107 state.queued.length = 0
108 state.ctrl?.abort()
109 stop.resolve({ type: "closed" })
110 finish()
111 }
112
113 const drain = () => {
114 if (draining || state.closed || state.queue.length === 0) {

Callers 1

runPromptQueueFunction · 0.70

Calls 2

finishFunction · 0.70
abortMethod · 0.45

Tested by

no test coverage detected