Make the upload dialog fire-and-forget #12
Loading…
Reference in a new issue
No description provided.
Delete branch "d/upload-fire-forget"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The dialog now only performs the uploads themselves: files are posted, a snackbar summarizes, and the dialog closes itself on a clean run � consumption tracking belonged to the webhook pipeline all along. Failures keep the dialog open with the per-file reason, and the whole flow is wrapped so an upload mishap can no longer take the circuit down.
🤖 Claude AI Code Review
Summary
Simplifies the upload dialog to a fire-and-forget POST flow, removing consumption tracking and adding snackbar summaries with a circuit-safe catch-all.
Code Quality ⭐⭐⭐⭐☆
Clean removal of dead state machinery; the fail-open catch and per-file status handling are well thought out.
Issues
🟡 UploadDialog.razor —
failedcount includes non-terminal states.failed = pendingRows.Count - queuedtreats any row that isn'tQueuedas failed. ButUploadRowAsync'scatch (IOException)(and any other status assignment) may leave rows in states likeUploadingif an exception propagates before status is set, and the outercatchaborts the loop mid-way — leaving remaining pending rows counted as "failed" and shown with an incorrect summary. Confirm every processed row reaches a terminal status (Queued/Rejected/Failed).🟢 UploadDialog.razor — outer
catch (Exception)swallows the error and leaves the dialog open, but the loop stops at the first unexpected exception, so subsequent pending rows are never attempted and their status staysPending(rendered as "failed" in the summary count). Consider whether partial progress should be reflected accurately.The
failedarithmetic is slightly fragile but only affects a summary count in edge cases; not a blocker. Worth a quick check that all rows reach a terminal state.📊 Tokens: 4548 input + 524 output | 💰 Cost: ~$0.0358
Generated by Claude Opus 4.8 via Gitea Actions