Skip to content

Fix stale durable live command blocking - #484

Merged
Pigbibi merged 1 commit into
mainfrom
codex/longbridge-failure-phase-20260916
Sep 16, 2026
Merged

Pigbibi merged 1 commit into
mainfrom
codex/longbridge-failure-phase-20260916

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Sep 16, 2026

Copy link
Copy Markdown
Collaborator

The live cycle validated every matching durable command before checking whether it was terminal. Historical commands with a stale runtime identity therefore raised ValueError and failed the cycle; a queued stale command must remain protected, while terminal history must not block or trigger a duplicate same-day command.

This change skips binding validation and reconciliation only for trusted terminal states. It first validates every unresolved command before reconciling any of them. A fixed invalid-binding result blocks the cycle without evaluating a new signal, claiming, writing command events or markers, or submitting orders. The report projects only the approved blocked reason; arbitrary error text is not included.

The existing queued command remains blocked. This PR does not cancel, rebind, delete, claim, or submit it, and it does not deploy or automatically restore live execution.

Validation:

  • PYTHONPATH="...worktree:...QPK d51...:...UES b83..." python3 -m pytest -q tests/test_rebalance_service.py tests/test_request_handling.py (120 passed, 22 subtests passed)
  • python3 -m ruff check application/rebalance_service.py main.py tests/test_rebalance_service.py tests/test_request_handling.py
  • git diff --check

Co-Authored-By: Codex <noreply@openai.com>
@Pigbibi
Pigbibi merged commit d5bbed4 into main Sep 16, 2026
1 check passed
@Pigbibi
Pigbibi deleted the codex/longbridge-failure-phase-20260916 branch September 16, 2026 00:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant