Skip to content

feat: progress elapsed time and remaining ETA with resume continuity - #12

Merged
phaethix merged 7 commits into
mainfrom
feat/progress-timing
Jul 24, 2026
Merged

feat: progress elapsed time and remaining ETA with resume continuity#12
phaethix merged 7 commits into
mainfrom
feat/progress-timing

Conversation

@phaethix

Copy link
Copy Markdown
Owner

Summary

  • Persist cumulative active generation time in state.json (active_elapsed_seconds) so checkpoint resume continues elapsed instead of resetting to 0
  • Expose elapsed_seconds / remaining_seconds on /api/job (linear ETA from progress; hide until ≥5%)
  • Show 已用 … · 预计还剩 … on the Web progress UI with a 1s local tick calibrated by poll

Test plan

  • .venv/bin/pytest -q green
  • Fresh generate: elapsed ticks from ~0; remaining appears after enough progress
  • Pause/resume same project_id: elapsed continues (idle gap not counted)
  • Supervisor 24h pause still uses session wall-clock only

Made with Cursor

phaethix and others added 7 commits July 24, 2026 10:35
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Seed web jobs from ProjectState.active_elapsed_seconds, track session
wall time via time.monotonic, and persist cumulative elapsed back to
state.json on progress ticks and job completion. GET /api/job now
refreshes and returns remaining_seconds for running jobs.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@phaethix
phaethix merged commit ecaced1 into main Jul 24, 2026
3 checks passed
@phaethix
phaethix deleted the feat/progress-timing branch July 24, 2026 03:08
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