Stuck#30
Merged
Merged
Conversation
Signed-off-by: JaredforReal <w13431838023@gmail.com>
Signed-off-by: JaredforReal <w13431838023@gmail.com>
There was a problem hiding this comment.
Pull request overview
This PR addresses “stuck” envelopes and updates the review workflow naming by renaming waiting_approval to in_review, adding startup recovery for envelopes left in processing, and adjusting session lifecycle handling so envelopes only enter processing when a session actually starts running.
Changes:
- Rename envelope status
WAITING_APPROVAL→IN_REVIEWacross backend, CLI, WebUI, and tests, with a DB migration to rewrite existing rows. - Add
Store.reset_processing_to_pending()and call it on daemon startup to recover envelopes stuck inPROCESSING. - Add a
QUEUEDsession status + sessionon_startcallback to transition envelopes toPROCESSINGwhen a queued session acquires a concurrency slot.
Reviewed changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/test_webui.py | Update status expectations from waiting_approval to in_review. |
| tests/test_store.py | Update unread-count/status tests; add coverage for resetting PROCESSING → PENDING. |
| tests/test_orchestrator.py | Align dispatch expectations with session spawning behavior. |
| tests/test_mailbox.py | Update persisted agent-log test to use IN_REVIEW. |
| tests/test_cli.py | Update default envelope status + CLI output assertions to in_review. |
| loom/webui/frontend/src/lib/types.ts | Update frontend EnvelopeStatus union to in_review. |
| loom/webui/frontend/src/lib/api.ts | Change envelope listing query construction; now requests limit=10000. |
| loom/webui/frontend/src/index.css | Rename CSS status token from --status-waiting to --status-review. |
| loom/webui/frontend/src/components/KanbanBoard.tsx | Rename “Waiting Approval” column to “In Review” and update grouping key. |
| loom/webui/frontend/src/components/Column.tsx | Update status color/token mapping to use review tokens/classes. |
| loom/webui/frontend/src/components/ActionsPanel.tsx | Update approve eligibility to in_review. |
| loom/state/store.py | Add migration to rewrite waiting_approval → in_review; update unread counts; add reset method. |
| loom/orchestrator/session.py | Introduce SessionStatus.QUEUED and on_start callback invoked when a session begins running. |
| loom/orchestrator/dispatcher.py | Move envelope PROCESSING transition to session-start callback; transition to IN_REVIEW on completion. |
| loom/daemon.py | Wire session start callback and reset stuck PROCESSING envelopes at startup. |
| loom/core/envelope.py | Rename enum member to IN_REVIEW. |
| loom/cli/view/theme.py | Update CLI theme keys and status glyph/style mapping for IN_REVIEW. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+12
to
+15
| const params = new URLSearchParams() | ||
| if (source) params.set("source", source) | ||
| params.set("limit", "10000") | ||
| return jsonFetch<Envelope[]>(`/api/envelopes?${params}`) |
Comment on lines
+335
to
337
| # Wire session lifecycle callbacks | ||
| session_mgr._on_start = dispatcher.handle_session_start | ||
| session_mgr._on_complete = dispatcher.handle_session_complete |
Comment on lines
24
to
28
| --radius: 0.5rem; | ||
| --status-queue: 215 16% 57%; | ||
| --status-processing: 221 83% 53%; | ||
| --status-waiting: 38 92% 50%; | ||
| --status-review: 38 92% 50%; | ||
| --status-done: 142 71% 45%; |
Comment on lines
+26
to
+28
| bg: "bg-[hsl(var(--status-review)/0.08)]", | ||
| dot: "bg-status-review", | ||
| label: "text-[hsl(var(--status-review))]", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.