Skip to content

fix(proxy): recover compact bridge replays - #1733

Closed
Komzpa wants to merge 8 commits into
Soju06:mainfrom
Komzpa:fix/post-compact-replay-watchdog-20260814
Closed

fix(proxy): recover compact bridge replays#1733
Komzpa wants to merge 8 commits into
Soju06:mainfrom
Komzpa:fix/post-compact-replay-watchdog-20260814

Conversation

@Komzpa

@Komzpa Komzpa commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Preserve completed tool_search_call / tool_search_output pairs when projecting account-neutral fresh replay payloads after compaction.
  • Treat a completed compaction item as retained self-contained context for durable full-resend recovery, including the compact + tool-search + fresh-user shape seen in live post-compaction stalls.
  • Keep the existing fail-closed guards for unsafe trim-only replay and required previous-response owners.

Live evidence

Fresh live readback on 2026-08-14 05:26 +04:00 showed /health and /health/ready green on live head ee602e520cb8348640948b90f6dc1c4b4c463d17, but request DB rows in the preceding 45 minutes still had post-compaction bridge failures: missing_response_created_timeout, stream_incomplete, and bridge_continuity_persistence_failed, while compaction rows themselves were mostly successful. That points at downstream bridge replay continuity, not the compact endpoint alone.

Validation

  • uv run pytest -q tests/unit/test_replay_safety.py -> 209 passed
  • uv run pytest -q tests/integration/test_http_responses_bridge.py -k 'quarantined_full_resend or account_neutral_replay or replays_full_resend_once' -> 3 passed, 126 deselected
  • openspec validate recover-post-compact-bridge-replays --strict -> valid
  • PR scope gate: git diff --name-only origin/main...HEAD contains only proxy replay/bridge code, OpenSpec, and focused tests.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fafc596622

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread app/modules/proxy/replay_safety.py
Comment thread app/modules/proxy/_service/http_bridge/mixin.py Outdated
Comment thread app/modules/proxy/_service/http_bridge/mixin.py Outdated
Comment thread app/modules/proxy/service.py Outdated
Comment thread app/modules/proxy/replay_safety.py
Comment thread app/modules/proxy/_service/http_bridge/mixin.py Outdated
@Komzpa
Komzpa force-pushed the fix/post-compact-replay-watchdog-20260814 branch from 29cce81 to 28e00dd Compare August 14, 2026 02:54
@Komzpa Komzpa added the 🤖 codex: needs work [@codex review] raised an issue label Aug 14, 2026
@Komzpa Komzpa removed the 🤖 codex: needs work [@codex review] raised an issue label Aug 14, 2026
@Komzpa

Komzpa commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1ccb3f1717

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread app/modules/proxy/replay_safety.py
Comment thread app/modules/proxy/replay_safety.py
@Komzpa
Komzpa force-pushed the fix/post-compact-replay-watchdog-20260814 branch from 1ccb3f1 to 0780d80 Compare August 14, 2026 04:32
@Komzpa

Komzpa commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: 0780d80715

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@Komzpa Komzpa added the 🤖 codex: ok [@codex review] says no issues found. label Aug 14, 2026
@Komzpa

Komzpa commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0780d80715

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread app/modules/proxy/_service/http_bridge/streaming.py Outdated
@Komzpa Komzpa added 🤖 codex: needs work [@codex review] raised an issue and removed 🤖 codex: ok [@codex review] says no issues found. labels Aug 14, 2026
@Komzpa

Komzpa commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator Author

Folded into #1744: post-compaction replay recovery joins the active-skill/compact-context carrier — one post-compaction context PR; history preserved via merge.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🤖 codex: needs work [@codex review] raised an issue

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant