Treat retryable Codex error notifications as runtime warnings#758
Merged
juliusmarminge merged 1 commit intomainfrom Mar 10, 2026
Merged
Treat retryable Codex error notifications as runtime warnings#758juliusmarminge merged 1 commit intomainfrom
juliusmarminge merged 1 commit intomainfrom
Conversation
- Map Codex `error` notifications with `willRetry: true` to `runtime.warning` - Keep active turns/sessions running during reconnect warnings - Add adapter and ingestion tests for retry-warning behavior
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
errornotifications withwillRetry: truetoruntime.warninginstead ofruntime.error.runtime.errorwithclass: provider_errorunchanged.runtime.warningwith the expected turn/message.running(with active turn preserved and nolastError) whenruntime.warningis received.Testing
apps/server/src/provider/Layers/CodexAdapter.test.ts(maps retryable Codex error notifications to runtime.warning).apps/server/src/orchestration/Layers/ProviderRuntimeIngestion.test.ts(keeps the session running when a runtime.warning arrives during an active turn).bun lint.bun typecheck.bun run test.Note
Medium Risk
Changes how Codex
errornotifications are classified, which can affect session erroring/alerting behavior ifwillRetryis set incorrectly. Scope is small and covered by new adapter + ingestion tests.Overview
Treats Codex
method: "error"notifications withpayload.willRetry: trueasruntime.warninginstead ofruntime.error, while keeping non-retryable errors mapped toruntime.errorwithclass: "provider_error".Adds coverage to verify the adapter emits
runtime.warningfor retryable errors, and that ingestion records the warning activity without flipping an in-flight session toerroror settinglastError.Written by Cursor Bugbot for commit 6d2b0df. This will update automatically on new commits. Configure here.
Note
Treat retryable Codex error notifications as
runtime.warninginstead ofruntime.errorIn
CodexAdapter.ts, themapToRuntimeEventsfunction now checkspayload.willRetryonerrormethod notifications. Whentrue, it emits aruntime.warningevent (withoutclass: provider_error) rather than aruntime.error, keeping the session in a running state. New tests cover both the adapter mapping and the downstream session behavior inProviderRuntimeIngestion.Macroscope summarized 6d2b0df.