Add a processing queue page with a live app-bar badge #13

Merged
cheapnud merged 1 commit from d/queue-page into master 2026-08-17 13:59:04 +00:00
Owner

A /queue page shows recent Paperless consume tasks (running first) with a functional health strip � reachability, latency, active and failed counts � refreshing quickly while work runs and lazily when idle. The app bar shows a count badge while anything is processing, and the upload toast links straight to the queue.

A /queue page shows recent Paperless consume tasks (running first) with a functional health strip � reachability, latency, active and failed counts � refreshing quickly while work runs and lazily when idle. The app bar shows a count badge while anything is processing, and the upload toast links straight to the queue.
Add a processing queue page with a live app-bar badge
All checks were successful
Claude PR Review / AI Code Review (pull_request) Successful in 16s
Build & Test / Build and Test (pull_request) Successful in 2m42s
186f911db5

🤖 Claude AI Code Review

  1. Summary
    Adds a /queue page with adaptive polling, an app-bar processing badge, and multi-version-aware task parsing in PaperlessClient. Well-structured and covered by new tests.

  2. Code Quality
    Clean separation, good null-vs-empty semantics for reachability, and thoughtful test coverage across Paperless response shapes.

  3. Issues

🟡 Queue.razor — LoadAsync can race with itself. The manual Refresh button and the PollLoopAsync timer both call LoadAsync concurrently. Overlapping fetches can assign _tasks/_lastFetchMs/_unreachable out of order, briefly showing stale or flickering state. Consider a guard (e.g. skip if a load is in flight) or a SemaphoreSlim.

🟢 Queue.razor — LoadAsync passes no CancellationToken to ListRecentTasksAsync, so on page close (Dispose) an in-flight fetch and its subsequent StateHasChanged are not cancelled. Pass _pollStopper.Token for consistency with the app-bar poller.

🟢 Queue.razor — context.TaskId[..8] assumes TaskId is at least 8 chars. If a shorter/empty task_id ever comes back this throws in the row template. Guard the substring length.

  1. Verdict: APPROVE

Minor concurrency hardening (in-flight guard + cancellation token) would be worth doing, but nothing here blocks merge.


📊 Tokens: 12022 input + 552 output | 💰 Cost: ~$0.0739
Generated by Claude Opus 4.8 via Gitea Actions

## 🤖 Claude AI Code Review 1. **Summary** Adds a `/queue` page with adaptive polling, an app-bar processing badge, and multi-version-aware task parsing in `PaperlessClient`. Well-structured and covered by new tests. 2. **Code Quality** ⭐⭐⭐⭐☆ Clean separation, good null-vs-empty semantics for reachability, and thoughtful test coverage across Paperless response shapes. 3. **Issues** 🟡 Queue.razor — `LoadAsync` can race with itself. The manual `Refresh` button and the `PollLoopAsync` timer both call `LoadAsync` concurrently. Overlapping fetches can assign `_tasks`/`_lastFetchMs`/`_unreachable` out of order, briefly showing stale or flickering state. Consider a guard (e.g. skip if a load is in flight) or a `SemaphoreSlim`. 🟢 Queue.razor — `LoadAsync` passes no `CancellationToken` to `ListRecentTasksAsync`, so on page close (`Dispose`) an in-flight fetch and its subsequent `StateHasChanged` are not cancelled. Pass `_pollStopper.Token` for consistency with the app-bar poller. 🟢 Queue.razor — `context.TaskId[..8]` assumes `TaskId` is at least 8 chars. If a shorter/empty task_id ever comes back this throws in the row template. Guard the substring length. 4. **Verdict**: **APPROVE** Minor concurrency hardening (in-flight guard + cancellation token) would be worth doing, but nothing here blocks merge. --- 📊 **Tokens**: 12022 input + 552 output | 💰 **Cost**: ~$0.0739 *Generated by Claude Opus 4.8 via Gitea Actions*
cheapnud merged commit 23376b9ad4 into master 2026-08-17 13:59:04 +00:00
cheapnud deleted branch d/queue-page 2026-08-17 13:59:04 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
cheapnud/CheapClerk!13
No description provided.