Skip to content

fix(server): expose stopped task results - #530

Merged
yltx merged 1 commit into
OpenWSGR:mainfrom
yltx:fix/server-stopped-task-results
Aug 4, 2026
Merged

fix(server): expose stopped task results#530
yltx merged 1 commit into
OpenWSGR:mainfrom
yltx:fix/server-stopped-task-results

Conversation

@yltx

@yltx yltx commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Summary

  • expose retained round results when a task finishes as stopped
  • return the same stopped-task summary through status polling and WebSocket completion
  • preserve cancellation semantics: WebSocket success stays false and cooperative stops keep error null
  • expose an explicit empty summary when cancellation happens before the first completed round

Contract

Stopped tasks now expose total_runs, success_runs, and full details instead of hiding retained results behind a null result.

TDD

The first cancellation regression failed on origin/main because TaskManager.get_status() returned a null result. The production change only extends the existing terminal-result projection to TaskStatus.STOPPED.

Verification

  • focused task tests: 20 passed
  • complete suite with coverage: 586 passed
  • Ruff check: passed
  • Ruff format: passed
  • codespell: passed
  • diff-cover against origin/main: 100% patch coverage

Scope

Only autowsgr/server/task_manager.py and its focused tests are changed. This PR does not alter scheduler behavior, decisive error mapping, response schemas, native types, or device leasing.

Copilot AI review requested due to automatic review settings August 4, 2026 03:18

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@yltx

yltx commented Aug 4, 2026

Copy link
Copy Markdown
Contributor Author

Coverage verification:

  • GitHub Pytest run completed successfully with 586 passed.
  • The CI Codecov uploader found coverage.xml and queued SHA 24625d9 successfully: https://app.codecov.io/github/openwsgr/autowsgr/commit/24625d9eceef107bfe6d579966d643a936d45240
  • Codecov test-results upload also queued successfully.
  • GitHub currently has no Codecov check/status for this SHA; this is absence of an external result, not a reported Codecov success or failure.
  • Equivalent local patch gate against origin/main: uvx diff-cover coverage.xml --compare-branch origin/main --fail-under=53.17
  • Result: 1 changed executable line, 0 missing, 100% patch coverage.

@codecov

codecov Bot commented Aug 4, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

@yltx
yltx merged commit 3c02cbb into OpenWSGR:main Aug 4, 2026
3 checks passed
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.

2 participants