Skip to content

Add Resume button to plan inspection page - #232

Merged
neoneye merged 1 commit into
mainfrom
feature/resume-button-frontend
Mar 10, 2026
Merged

Add Resume button to plan inspection page#232
neoneye merged 1 commit into
mainfrom
feature/resume-button-frontend

Conversation

@neoneye

Copy link
Copy Markdown
Member

Summary

  • Adds a Resume button next to Retry on the plan inspection page, giving users access to the plan_resume functionality (PR Add plan_resume MCP tool for mid-pipeline recovery #217) from the multi-user frontend
  • Resume preserves all completed intermediary files and continues from where the plan left off; Retry discards everything and starts over
  • New /plan/resume POST endpoint validates failed state, checks pipeline version compatibility, and creates an audit trail via EventItem
  • Both buttons share a single <form> with formaction, using one model_profile dropdown; Resume is only enabled when state is failed (not stop_requested)

Test plan

  • docker compose up and create a plan
  • Stop a running plan → verify Retry is active, Resume is disabled (stop_requested state)
  • Wait for plan to reach failed state → verify both Retry and Resume are active
  • Hover over each button → verify tooltips appear ("Discard all progress..." / "Continue from where it left off...")
  • Click Resume on a failed plan → plan restarts as pending, artifacts preserved
  • On a completed plan → verify both buttons are disabled (greyed out)
  • Attempt Resume with a pipeline version mismatch → verify 409 error response

🤖 Generated with Claude Code

@neoneye
neoneyeforce-pushed the feature/resume-button-frontend branch 2 times, most recently from 379780a to f8fbe7cCompareMarch 10, 2026 01:28
The plan_resume MCP tool (PR #217) supports resuming failed plans
without discarding completed intermediary files. This adds a Resume
button next to Retry in the multi-user frontend so users can access
this functionality from the UI.
Frontend endpoint (/plan/resume):
- Validates owner/admin auth, rejects non-failed state
- Checks pipeline_version compatibility; redirects with error banner
on mismatch instead of showing raw JSON
- Preserves all artifacts (key difference from retry)
- Sets resume=True, increments resume_count, archives billing entries
- Does NOT stamp pipeline_version — leaves that to the worker after
successful artifact validation
- Adds EventItem audit trail
Template (plan_iframe.html):
- Shared form with formaction for Retry and Resume buttons
- Resume only enabled in failed state (not stop_requested)
- Tooltips explain the difference between the two actions
- Inline error banner when resume is rejected due to version mismatch
Worker fix (worker_plan_database/app.py):
- Truncate progress_message to fit varchar(128) column, fixing a
StringDataRightTruncation crash on pipeline version mismatch
- Clear pipeline_version from parameters on mismatch rejection so
subsequent frontend resume attempts are correctly blocked
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@neoneye
neoneyeforce-pushed the feature/resume-button-frontend branch from f8fbe7c to 41c1dcdCompareMarch 10, 2026 01:35
@neoneye
neoneye merged commit cdae4b9 into mainMar 10, 2026
3 checks passed
@neoneye
neoneye deleted the feature/resume-button-frontend branch March 10, 2026 01:39
Sign up for freeto 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

@neoneye