Skip to content

Preserve native ACP artifacts at prompt timeout - #1051

Open
kywch wants to merge 7 commits into
mainfrom
fix/graceful-acp-timeout
Open

Preserve native ACP artifacts at prompt timeout#1051
kywch wants to merge 7 commits into
mainfrom
fix/graceful-acp-timeout

Conversation

@kywch

@kywch kywch commented Aug 23, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • send ACP session/cancel before locally cancelling timed-out prompt tasks
  • wait up to 5 seconds for terminal tool updates and final PromptResponse.usage
  • keep hard-cancel fallback bounded and mark unresolved tool calls partial
  • apply same cancellation sequence to wall-clock and idle timeouts

Why

Native subscription usage arrives on final ACP prompt response. Immediate local task cancellation discarded that response, left tool calls pending, and made otherwise normal wall-clock timeouts artifact-incomplete.

Verification

  • uv run pytest -q tests/test_acp.py tests/test_native_acp_usage.py tests/test_trajectory_streaming.py tests/test_session_factory_runtime.py (136 passed)
  • uv run ruff check src/benchflow/acp/runtime.py tests/test_acp.py tests/test_native_acp_usage.py
  • uv run ty check src/benchflow/acp/runtime.py

No live experiment rerun performed.


Open in Devin Review

@kywch
kywch deployed to pypi-internal-preview August 23, 2026 00:17 — with GitHub Actions Active
@kywch
kywch deployed to pypi-internal-preview August 23, 2026 00:18 — with GitHub Actions Active

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Open in Devin Review

@kywch
kywch deployed to pypi-internal-preview August 23, 2026 00:24 — with GitHub Actions Active
@kywch
kywch deployed to pypi-internal-preview August 23, 2026 00:26 — with GitHub Actions Active
@kywch
kywch deployed to pypi-internal-preview August 23, 2026 01:29 — with GitHub Actions Active
@kywch
kywch deployed to pypi-internal-preview August 23, 2026 06:43 — with GitHub Actions Active
@kywch
kywch deployed to pypi-internal-preview August 23, 2026 06:49 — with GitHub Actions Active
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