[codex] Add Pi provider integration #2831
ClosedAmbitiousRealism2025(GitHub profile, opens in a new tab)wants to merge 3 commits into
main fromrefs/pull/2831/headopened View on GitHubgithub-actions[bot](GitHub profile, opens in a new tab) added labelssize:XXL
github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched
- @@ -0,0 +181,21 @@181+ reject(error);182+ };183+184+ const timeoutMs = input.timeoutMs ?? 120_000;185+ let timer: ReturnType<typeof setTimeout>;186+ const resetTimer = () => {187+ clearTimeout(timer);188+ // @effect-diagnostics-next-line globalTimers:off189+ timer = setTimeout(() => {190+ rejectOnce(new Error(`Timed out waiting for Pi RPC. Stderr: ${stderr.trim()}`));191+ }, timeoutMs);192+ };193+194+ // @effect-diagnostics-next-line globalTimers:off195+ timer = setTimeout(() => {196+ rejectOnce(new Error(`Timed out waiting for Pi RPC. Stderr: ${stderr.trim()}`));197+ }, timeoutMs);198+199+ input.signal?.addEventListener("abort", () => {200+ rejectOnce(new Error("Pi RPC request was aborted."));201+ });@@ -0,0 +265,21 @@265+ mimeType: attachment.mimeType,266+ };267+ },268+ catch: (cause) =>269+ new ProviderAdapterRequestError({270+ provider: PROVIDER,271+ method: "prompt",272+ detail: errorDetail(cause),273+ cause,274+ }),275+ });276+277+ const startSession: PiAdapterShape["startSession"] = (input) =>278+ Effect.gen(function* () {279+ if (input.provider !== undefined && input.provider !== PROVIDER) {280+ return yield* new ProviderAdapterValidationError({281+ provider: PROVIDER,282+ operation: "startSession",283+ issue: `Expected provider '${PROVIDER}' but received '${input.provider}'.`,284+ });285+ }
Sign in to join this conversation.
Important
Review skipped#
Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
.coderabbit.yamlfile in this repository. To trigger a single review, invoke the@coderabbitai reviewcommand.⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
Run ID:
275c764f-0fd0-455c-b361-f827f608b4fcYou can disable this status message by setting the
reviews.review_statustofalsein the CodeRabbit configuration file.Use the checkbox below for a quick retry:
✨ Finishing Touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share