MCPcopy Create free account
hub / github.com/MoonshotAI/kimi-code / tryRun

Function tryRun

apps/kimi-code/test/cli/provider.test.ts:130–137  ·  view source on GitHub ↗
(fn: () => Promise<T>)

Source from the content-addressed store, hash-verified

128}
129
130async function tryRun<T>(fn: () => Promise<T>): Promise<T | undefined> {
131 try {
132 return await fn();
133 } catch (error) {
134 if (error instanceof ExitCalled) return undefined;
135 throw error;
136 }
137}
138
139const REGISTRY_URL = 'https://registry.example.test/v1/models/api.json';
140const REGISTRY_BODY = {

Callers 1

provider.test.tsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected