ticket: use base32 project record ids
This commit is contained in:
@@ -0,0 +1,122 @@
|
||||
# Delegation intent: explicit Ticket workflow state
|
||||
|
||||
## Classification
|
||||
|
||||
`implementation-ready` after `typed-ticket-thread-event-log`.
|
||||
|
||||
The typed thread event foundation is complete. This ticket should add explicit durable workflow state to Ticket records and update the panel/queue action to use it instead of inferred phase/action/status heuristics.
|
||||
|
||||
## Intent
|
||||
|
||||
Replace inferred panel Ticket state with explicit Ticket workflow fields and simplify the panel main list to display durable state directly.
|
||||
|
||||
Durable workflow state:
|
||||
|
||||
```text
|
||||
intake -> ready -> queued -> inprogress -> done
|
||||
```
|
||||
|
||||
The only normal human gate is `ready -> queued`, exposed as `Queue` in the panel. Review/rework/validation remain within `inprogress`; transient activity should not be stored in Ticket frontmatter.
|
||||
|
||||
## Worktree / branch
|
||||
|
||||
- worktree: `/home/hare/Projects/yoi/.worktree/explicit-ticket-workflow-state`
|
||||
- branch: `work/explicit-ticket-workflow-state`
|
||||
|
||||
This ticket may read tracked `.yoi/tickets` records/design artifacts. Do not read or edit `.yoi/memory/`.
|
||||
|
||||
## Requirements
|
||||
|
||||
- Add typed workflow fields to Ticket frontmatter/model parsing/writing:
|
||||
- `workflow_state: intake | ready | queued | inprogress | done`;
|
||||
- `attention_required: null | "..."` or compatible optional string overlay;
|
||||
- `queued_by: null | "user"` or compatible optional string;
|
||||
- `queued_at: null | timestamp` or compatible optional timestamp/string.
|
||||
- Preserve existing Tickets through safe defaults/migration behavior.
|
||||
- Existing open Tickets without `workflow_state` should not be guessed from title/labels/thread as authoritative state.
|
||||
- Use a conservative default such as `intake` or `ready` only if documented and tested; if the current status is closed, map to `done` where appropriate.
|
||||
- Use the typed thread event APIs from `typed-ticket-thread-event-log` for state changes where practical:
|
||||
- `ready -> queued` should update frontmatter and append `state_changed` as one logical mutation;
|
||||
- the event should record actor/reason and remain concise.
|
||||
- Update `yoi panel` to display workflow state directly.
|
||||
- Simplify panel main-list rows:
|
||||
- Ticket rows: `<sel> <state> <slug-or-id> <title>`;
|
||||
- Pod rows: `<sel> <pod-state> <pod-name>`;
|
||||
- remove permanent priority/action/status/phase columns from main rows.
|
||||
- Move row-specific operations such as Queue/Defer/Open/Send to selected-row actionbar/key hints instead of always-visible row columns.
|
||||
- Keep composer/status bar concise and stable; move verbose target/help/diagnostics to actionbar/detail/diagnostic area.
|
||||
- Remove or demote heuristics that infer phase/action from labels, title text, `readiness`, `needs_preflight`, or thread event presence.
|
||||
- Rename panel `Go`/`ApproveIntake` queue-like behavior to `Queue`.
|
||||
- Queue action semantics:
|
||||
- only valid when current `workflow_state == ready`;
|
||||
- re-check state before mutation;
|
||||
- transition to `queued`;
|
||||
- set `queued_by` / `queued_at` if adopted;
|
||||
- append typed `state_changed` event;
|
||||
- notify Orchestrator if reachable, but notification failure must not roll back a successful Ticket transition.
|
||||
- `Defer` may remain as a safe status/pending action if currently useful, but it should not pretend to be workflow state unless explicitly modeled.
|
||||
- Intake readiness:
|
||||
- add API/tool/helper path for Intake/Orchestrator to mark a Ticket `ready` using explicit state and, where practical, an `intake_summary`/`state_changed` event;
|
||||
- do not dump full Intake transcripts into Ticket thread.
|
||||
- Done/close flow should set or derive `workflow_state = done` consistently.
|
||||
- No-Ticket workspace Pod-centric panel behavior must remain unchanged.
|
||||
- Do not store transient `activity` in frontmatter.
|
||||
- Do not reintroduce `--multi` or `:ticket`.
|
||||
|
||||
## Current code map
|
||||
|
||||
- `crates/ticket/src/lib.rs`
|
||||
- Ticket item/frontmatter parsing/writing, `Ticket` model, backend APIs.
|
||||
- Newly available typed event APIs: `TicketStateChange`, `TicketIntakeSummary`, `add_state_changed`, `add_intake_summary`, `set_state_field`.
|
||||
- `crates/ticket/src/tool.rs`
|
||||
- Built-in Ticket tool behavior. Add workflow state support only if needed for Intake/Orchestrator/Panel flows.
|
||||
- `crates/yoi/src/ticket_cli.rs`
|
||||
- Direct CLI. Update display/create behavior only if needed; keep CLI stable.
|
||||
- `crates/tui/src/workspace_panel.rs`
|
||||
- Current inferred `TicketPanelPhase`, `NextUserAction`, row derivation heuristics.
|
||||
- `crates/tui/src/multi_pod.rs`
|
||||
- Panel row rendering, Queue/Defer action dispatch, status/action bar text, Orchestrator notification.
|
||||
- `crates/client/src/ticket_role.rs`
|
||||
- Intake/Orchestrator role launch context if state-ready/intake-summary integration needs launch-prompt changes.
|
||||
|
||||
## Non-goals
|
||||
|
||||
- Scheduler/lease/queue system.
|
||||
- Persisting live Pod activity into Tickets.
|
||||
- Reintroducing human approve/reject gates for every review loop.
|
||||
- Reintroducing `--multi` or `:ticket`.
|
||||
- Broad layout redesign beyond the required state-only row/statusbar simplification.
|
||||
|
||||
## Validation
|
||||
|
||||
Run at least:
|
||||
|
||||
- `cargo test -p ticket workflow` or targeted workflow-state tests;
|
||||
- `cargo test -p ticket`;
|
||||
- `cargo test -p tui workspace_panel`;
|
||||
- `cargo test -p tui multi_pod`;
|
||||
- `cargo test -p yoi panel`;
|
||||
- `cargo test -p yoi ticket` if CLI behavior changes;
|
||||
- `cargo test -p pod ticket --lib` if tools change;
|
||||
- `cargo check --workspace --all-targets`;
|
||||
- `cargo fmt --check`;
|
||||
- `git diff --check`;
|
||||
- `cargo build -p yoi`;
|
||||
- `target/debug/yoi ticket doctor`.
|
||||
|
||||
Run `nix build .#yoi --no-link` if feasible.
|
||||
|
||||
## Completion report
|
||||
|
||||
Report:
|
||||
|
||||
- worktree path / branch;
|
||||
- commit hash;
|
||||
- final frontmatter fields and default/migration behavior;
|
||||
- state transition API usage;
|
||||
- Queue semantics and Orchestrator notification behavior;
|
||||
- panel row/statusbar simplification;
|
||||
- heuristics removed/demoted;
|
||||
- tests updated/added;
|
||||
- validation results;
|
||||
- remaining follow-up items, if any.
|
||||
@@ -0,0 +1,141 @@
|
||||
---
|
||||
title: "Replace inferred panel Ticket state with explicit workflow state"
|
||||
state: "closed"
|
||||
created_at: "2026-06-06T21:54:03Z"
|
||||
updated_at: "2026-06-07T00:08:04Z"
|
||||
---
|
||||
|
||||
## Background
|
||||
|
||||
The first-pass workspace panel derives Ticket phase/action/status from labels, title text, readiness fields, and thread events such as `plan`, `implementation_report`, and `review`. That was useful for bootstrapping the panel, but it makes the panel infer workflow state instead of reading explicit Ticket state.
|
||||
|
||||
The desired model is simpler and more durable: Ticket records should carry a small explicit workflow state, while transient execution activity remains derived from live Pod/session state and is not persisted into Ticket frontmatter.
|
||||
|
||||
## Goal
|
||||
|
||||
Replace panel-inferred Ticket workflow state with explicit Ticket workflow fields and update the panel/Orchestrator/Intake flows to use those fields.
|
||||
|
||||
## Target state model
|
||||
|
||||
Use a small durable state machine:
|
||||
|
||||
```text
|
||||
intake -> ready -> queued -> inprogress -> done
|
||||
```
|
||||
|
||||
Meanings:
|
||||
|
||||
- `intake`: Intake Pod and user are clarifying/materializing the Ticket.
|
||||
- `ready`: Intake is complete; the Ticket is ready for a human to queue.
|
||||
- `queued`: Human queued the Ticket; Orchestrator may schedule it when resources/priority allow.
|
||||
- `inprogress`: Orchestrator/coder/reviewer/validator work is underway. Review/rework loops stay inside this state.
|
||||
- `done`: completed/closed.
|
||||
|
||||
`blocked` is not a workflow state. Blocking/user attention is an overlay such as `attention_required`.
|
||||
|
||||
`review` is not a workflow state. Review/rework/validation are runtime activity or thread events inside `inprogress`.
|
||||
|
||||
## Durable fields
|
||||
|
||||
Add explicit current-state fields to Ticket frontmatter, for example:
|
||||
|
||||
```yaml
|
||||
workflow_state: intake | ready | queued | inprogress | done
|
||||
attention_required: null | "..."
|
||||
queued_by: null | "user"
|
||||
queued_at: null | "2026-..."
|
||||
```
|
||||
|
||||
Exact field names can be refined during implementation, but the semantics should remain:
|
||||
|
||||
- `workflow_state` is the durable Ticket workflow state.
|
||||
- `attention_required` is a durable human-attention overlay, not a separate workflow state.
|
||||
- `queued_by` / `queued_at` are durable facts recorded when the user queues a ready Ticket.
|
||||
|
||||
Do not persist `activity` in Ticket frontmatter. Current activity such as implementing/reviewing/validating should be displayed by combining Ticket state with live Pod/session/role-launch metadata and latest thread events.
|
||||
|
||||
## Panel display simplification
|
||||
|
||||
Once explicit workflow state exists, the panel row should stop showing multiple near-synonymous columns such as priority/action/status/phase. For Ticket rows, the main list should show only the durable state plus identity/title:
|
||||
|
||||
```text
|
||||
<sel> <state> <slug-or-id> <title>
|
||||
```
|
||||
|
||||
Actions such as `Queue`, `Defer`, or `Open` should move to the actionbar/key-hint area for the selected row, not occupy a permanent row column. Ticket priority and other metadata can appear in the detail pane when useful, not as primary list columns.
|
||||
|
||||
Pod rows should follow the same principle:
|
||||
|
||||
```text
|
||||
<sel> <pod-state> <pod-name>
|
||||
```
|
||||
|
||||
Pod operations such as send/open should also be shown as selected-row key hints/actions, not as a permanent noisy row column.
|
||||
|
||||
The panel composer/status area should also be simplified. Do not put verbose target/help/diagnostic text in the status bar. Keep the status bar concise and stable; put transient guidance/errors in the actionbar or detail/diagnostic area instead.
|
||||
|
||||
## Flow
|
||||
|
||||
- `intake -> ready` is completed through Intake Pod conversation and Ticket materialization.
|
||||
- `ready -> queued` is the normal human panel action.
|
||||
- `queued -> inprogress` is performed by Orchestrator scheduling.
|
||||
- `inprogress -> done` is performed by Orchestrator/review/close flow when complete.
|
||||
|
||||
The panel action currently called `Go` should become `Queue`, because the user is queuing a ready Ticket rather than approving implementation details.
|
||||
|
||||
## Thread/event-log relationship
|
||||
|
||||
Current workflow state should live in frontmatter, but every workflow state transition should be explainable through a concise append-only thread event. The thread should become a typed event log, not a freeform conversation transcript.
|
||||
|
||||
This is split into companion ticket `typed-ticket-thread-event-log` so this Ticket can focus on current-state fields and panel semantics while the companion defines/implements the event-log API.
|
||||
|
||||
Desired split:
|
||||
|
||||
- `item.md` frontmatter: current workflow state authority.
|
||||
- `item.md` body: current Ticket snapshot.
|
||||
- `thread.md`: typed append-only events such as `state_changed`, `intake_summary`, `decision`, `implementation_report`, `review`, and `close`.
|
||||
- Pod/session logs: full conversations/runtime transcript.
|
||||
|
||||
State mutations should eventually use backend APIs that update frontmatter and append a `state_changed` event as one logical operation. Intake should write a concise `intake_summary` instead of copying the full Intake conversation into the Ticket thread.
|
||||
|
||||
## Requirements
|
||||
|
||||
- Add explicit workflow state fields to the Ticket model/parser/writer and tool/CLI surfaces as needed.
|
||||
- Migrate or default existing Tickets safely without relying on labels/title/thread-event heuristics as authoritative state.
|
||||
- Update `yoi panel` to display `workflow_state` directly.
|
||||
- Simplify Ticket rows to state + identity/title only: remove permanent priority/action/status/phase columns from the main row.
|
||||
- Simplify Pod rows to pod-state + pod-name only: remove permanent action/kind columns from the main row.
|
||||
- Move row-specific operations such as Queue/Defer/Open/Send to selected-row actionbar/key hints rather than always-visible row columns.
|
||||
- Keep composer/status bar text concise; avoid verbose target/help/diagnostic clutter in the status bar.
|
||||
- Put transient guidance/errors in the actionbar or diagnostic/detail area instead of the status bar.
|
||||
- Remove or demote current panel heuristics that infer phase/action from labels, title text, `readiness`, `needs_preflight`, or thread event presence.
|
||||
- Rename panel `Go` action to `Queue` and make it transition `ready -> queued`.
|
||||
- Queue action must re-check current Ticket state before mutation.
|
||||
- Queue action records a durable typed `state_changed` / decision event and sets `queued_by` / `queued_at` if those fields are adopted.
|
||||
- Orchestrator should treat `queued` as schedulable and set `inprogress` when it starts work, with a typed state transition event once the companion event-log API exists.
|
||||
- Intake should set `workflow_state = ready` when the Ticket is fully materialized and ready to queue.
|
||||
- Done/close flow should set `workflow_state = done` or derive it consistently from close status.
|
||||
- Do not store transient `activity` in Ticket frontmatter.
|
||||
- Preserve no-Ticket workspace Pod-centric panel behavior.
|
||||
|
||||
## Non-goals
|
||||
|
||||
- Building the full typed thread event-log API; companion ticket `typed-ticket-thread-event-log` owns that, though this ticket should align with it.
|
||||
- Persisting live Pod activity into Tickets.
|
||||
- Reintroducing human approve/reject gates for every review loop.
|
||||
- Reintroducing `--multi` or `:ticket`.
|
||||
- Layout-only tuning unrelated to explicit state, except the required state-only row/statusbar simplification described above.
|
||||
|
||||
## Acceptance criteria
|
||||
|
||||
- New/updated Tickets can carry explicit workflow state.
|
||||
- Panel rows show workflow state from Ticket fields rather than inferred phase/status.
|
||||
- Ticket rows use a minimal `state + slug/id + title` shape; priority/action/status/phase are not permanent main-list columns.
|
||||
- Pod rows use a minimal `pod-state + pod-name` shape; operations are shown as selected-row key hints/actions, not permanent main-list columns.
|
||||
- Composer/status bar text is concise and does not contain verbose target/help/diagnostic clutter.
|
||||
- Ready Tickets show `Queue` rather than `Go` as the selected-row actionbar/key-hint action.
|
||||
- Queue action transitions only `ready -> queued` and rejects stale/invalid states.
|
||||
- Review/rework activity does not create a separate workflow state; it remains `inprogress` plus runtime/thread detail.
|
||||
- No persistent `activity` field is required for current Pod activity.
|
||||
- Existing tests cover default/migration behavior, panel display, Queue dispatch, and stale-state rejection.
|
||||
- Companion ticket `typed-ticket-thread-event-log` exists and captures the append-only state transition / Intake summary event-log work if not implemented in the same change series.
|
||||
@@ -0,0 +1,51 @@
|
||||
Implemented explicit Ticket workflow state.
|
||||
|
||||
Final frontmatter fields:
|
||||
- `workflow_state: intake | ready | queued | inprogress | done`
|
||||
- `attention_required: null | "..."`
|
||||
- `queued_by: null | "..."`
|
||||
- `queued_at: null | "..."`
|
||||
|
||||
State/default behavior:
|
||||
- Closed Tickets default/derive to `done` where appropriate.
|
||||
- Existing non-closed Tickets without explicit workflow state use conservative defaults without treating labels/title/thread heuristics as workflow-state authority.
|
||||
- Transient activity such as reviewing/reworking/validating is not persisted in frontmatter.
|
||||
|
||||
Workflow transition APIs/tools:
|
||||
- `mark_intake_ready` / `TicketIntakeReady` performs `intake -> ready`, appending typed `intake_summary` and `state_changed` events.
|
||||
- `queue_ready` remains the dedicated panel Queue path for `ready -> queued`, sets queued metadata, and appends typed `state_changed`.
|
||||
- `set_workflow_state` / `TicketWorkflowState` is bounded to role-side transitions `queued -> inprogress` and `inprogress -> done`.
|
||||
- Generic `set_state_field(..., "workflow_state", ...)` is rejected to prevent bypass.
|
||||
- Backward/skip transitions such as `ready -> inprogress`, `queued -> done`, and `done -> intake` are rejected.
|
||||
|
||||
Panel changes:
|
||||
- Panel rows display explicit workflow state directly.
|
||||
- Ticket rows are simplified to state + slug/id + title.
|
||||
- Pod rows are simplified to pod-state + pod-name.
|
||||
- Row operations move to selected-row actionbar/key hints instead of permanent action/status/phase columns.
|
||||
- Queue replaces the previous Go/ApproveIntake wording and is only valid for current `workflow_state == ready`.
|
||||
- Queue notifies Orchestrator when reachable; notification failure does not roll back a successful Ticket transition.
|
||||
- No-Ticket Pod-centric panel behavior is preserved.
|
||||
|
||||
Role prompt/tool behavior:
|
||||
- Intake/Orchestrator role text now uses `workflow_state` / `Queue` vocabulary.
|
||||
- Intake is instructed to set `workflow_state = ready` through typed Ticket tools after materializing a Ticket.
|
||||
- Orchestrator treats `queued` as schedulable and moves to `inprogress` when starting.
|
||||
|
||||
Validation after merge:
|
||||
- `cargo test -p ticket workflow --lib`
|
||||
- `cargo test -p ticket`
|
||||
- `cargo test -p tui workspace_panel --lib`
|
||||
- `cargo test -p tui multi_pod --lib`
|
||||
- `cargo test -p yoi panel`
|
||||
- `cargo test -p yoi ticket`
|
||||
- `cargo test -p pod ticket --lib`
|
||||
- `cargo test -p client ticket_role`
|
||||
- `cargo check --workspace --all-targets`
|
||||
- `cargo fmt --check`
|
||||
- `git diff --check HEAD~1..HEAD`
|
||||
- `cargo build -p yoi`
|
||||
- `target/debug/yoi ticket doctor`
|
||||
- `nix build .#yoi --no-link --print-out-paths`
|
||||
|
||||
External review approved after transition-graph enforcement was added.
|
||||
@@ -0,0 +1,163 @@
|
||||
<!-- event: create author: yoi ticket at: 2026-06-06T21:54:03Z -->
|
||||
|
||||
## Created
|
||||
|
||||
Created by LocalTicketBackend create.
|
||||
|
||||
---
|
||||
|
||||
<!-- event: plan author: hare at: 2026-06-06T21:54:48Z -->
|
||||
|
||||
## Plan
|
||||
|
||||
Created from design discussion about removing inferred panel Ticket state.
|
||||
|
||||
Decision recorded:
|
||||
- stop treating panel heuristics from labels/title/thread events as authoritative workflow state;
|
||||
- add an explicit durable Ticket workflow state: `intake -> ready -> queued -> inprogress -> done`;
|
||||
- `intake -> ready` is completed through Intake Pod conversation/materialization;
|
||||
- `ready -> queued` is the normal human panel action, replacing the current `Go` action with `Queue`;
|
||||
- review/rework stay inside `inprogress`;
|
||||
- blocked/user-attention is an overlay such as `attention_required`, not a workflow state;
|
||||
- transient activity should be derived from live Pod/session/thread state and not persisted in Ticket frontmatter.
|
||||
|
||||
|
||||
---
|
||||
|
||||
<!-- event: decision author: hare at: 2026-06-06T22:04:15Z -->
|
||||
|
||||
## Decision
|
||||
|
||||
Updated per user direction:
|
||||
|
||||
- Ticket row should not expose priority/action/status/phase as separate permanent columns; they are redundant once explicit workflow state exists.
|
||||
- Ticket rows should be essentially `state + slug/id + title`.
|
||||
- Pod rows should likewise be essentially `pod-state + pod-name`.
|
||||
- Operations such as Queue/Defer/Open/Send should move to selected-row actionbar/key hints instead of row columns.
|
||||
- Composer/status bar should be kept concise; verbose target/help/diagnostic text should move to actionbar or detail/diagnostic areas.
|
||||
|
||||
|
||||
---
|
||||
|
||||
<!-- event: decision author: hare at: 2026-06-06T22:14:29Z -->
|
||||
|
||||
## Decision
|
||||
|
||||
Updated based on thread/event-log discussion and split out companion work.
|
||||
|
||||
Decision:
|
||||
- Do not delete Ticket threads.
|
||||
- Do not use threads as freeform AI conversation dumps.
|
||||
- Use `item.md` frontmatter for current workflow state, `item.md` body for the current Ticket snapshot, `thread.md` as a concise typed append-only event log, and Pod/session logs for full conversations.
|
||||
- Workflow state transitions should eventually update frontmatter and append a `state_changed` event as one logical backend operation.
|
||||
- Intake should write a bounded `intake_summary` when materializing/marking a Ticket ready, not copy the full Intake conversation.
|
||||
|
||||
Created companion ticket `typed-ticket-thread-event-log` for the typed thread event model/API so `explicit-ticket-workflow-state` can stay focused on current-state fields and panel semantics.
|
||||
|
||||
|
||||
---
|
||||
|
||||
<!-- event: plan author: hare at: 2026-06-06T22:49:29Z -->
|
||||
|
||||
## Plan
|
||||
|
||||
Preflight result: `implementation-ready` after `typed-ticket-thread-event-log`.
|
||||
|
||||
This ticket should add explicit durable Ticket workflow fields and update the panel to stop using inferred state/action/status columns. The core workflow is `intake -> ready -> queued -> inprogress -> done`; `ready -> queued` is the normal human panel action and should be shown as `Queue`, not `Go`.
|
||||
|
||||
Implementation should use the newly-added typed thread event APIs for state transitions where practical, simplify panel rows to state + identity/title, and keep transient Pod activity out of Ticket frontmatter.
|
||||
|
||||
Detailed delegation intent is recorded in `artifacts/delegation-intent.md`.
|
||||
|
||||
|
||||
---
|
||||
|
||||
<!-- event: review author: hare at: 2026-06-07T00:08:04Z status: approve -->
|
||||
|
||||
## Review: approve
|
||||
|
||||
External reviewer approved current HEAD after two requested-changes cycles.
|
||||
|
||||
Review summary:
|
||||
- Explicit workflow fields and panel display are implemented.
|
||||
- Ticket rows are state + id/title oriented and no longer use inferred priority/action/status/phase as main-list authority.
|
||||
- Queue re-checks current state and transitions ready -> queued through the dedicated backend path.
|
||||
- Typed tools expose bounded Intake and Orchestrator workflow transitions.
|
||||
- Workflow transition graph is centrally enforced:
|
||||
- IntakeReady only permits intake -> ready.
|
||||
- Queue path owns ready -> queued.
|
||||
- Role-side TicketWorkflowState permits queued -> inprogress and inprogress -> done.
|
||||
- Backward/skip/bypass transitions are rejected.
|
||||
- Handoff prompt uses workflow_state / Queue vocabulary instead of old readiness/Go wording.
|
||||
- No transient activity is persisted in frontmatter.
|
||||
|
||||
|
||||
---
|
||||
|
||||
<!-- event: state_changed author: hare at: 2026-06-07T00:08:04Z from: intake to: done reason: closed field: workflow_state -->
|
||||
|
||||
## State changed
|
||||
|
||||
Ticket closed; workflow_state set to done.
|
||||
|
||||
|
||||
---
|
||||
|
||||
<!-- event: close author: hare at: 2026-06-07T00:08:04Z status: closed -->
|
||||
|
||||
## Closed
|
||||
|
||||
Implemented explicit Ticket workflow state.
|
||||
|
||||
Final frontmatter fields:
|
||||
- `workflow_state: intake | ready | queued | inprogress | done`
|
||||
- `attention_required: null | "..."`
|
||||
- `queued_by: null | "..."`
|
||||
- `queued_at: null | "..."`
|
||||
|
||||
State/default behavior:
|
||||
- Closed Tickets default/derive to `done` where appropriate.
|
||||
- Existing non-closed Tickets without explicit workflow state use conservative defaults without treating labels/title/thread heuristics as workflow-state authority.
|
||||
- Transient activity such as reviewing/reworking/validating is not persisted in frontmatter.
|
||||
|
||||
Workflow transition APIs/tools:
|
||||
- `mark_intake_ready` / `TicketIntakeReady` performs `intake -> ready`, appending typed `intake_summary` and `state_changed` events.
|
||||
- `queue_ready` remains the dedicated panel Queue path for `ready -> queued`, sets queued metadata, and appends typed `state_changed`.
|
||||
- `set_workflow_state` / `TicketWorkflowState` is bounded to role-side transitions `queued -> inprogress` and `inprogress -> done`.
|
||||
- Generic `set_state_field(..., "workflow_state", ...)` is rejected to prevent bypass.
|
||||
- Backward/skip transitions such as `ready -> inprogress`, `queued -> done`, and `done -> intake` are rejected.
|
||||
|
||||
Panel changes:
|
||||
- Panel rows display explicit workflow state directly.
|
||||
- Ticket rows are simplified to state + slug/id + title.
|
||||
- Pod rows are simplified to pod-state + pod-name.
|
||||
- Row operations move to selected-row actionbar/key hints instead of permanent action/status/phase columns.
|
||||
- Queue replaces the previous Go/ApproveIntake wording and is only valid for current `workflow_state == ready`.
|
||||
- Queue notifies Orchestrator when reachable; notification failure does not roll back a successful Ticket transition.
|
||||
- No-Ticket Pod-centric panel behavior is preserved.
|
||||
|
||||
Role prompt/tool behavior:
|
||||
- Intake/Orchestrator role text now uses `workflow_state` / `Queue` vocabulary.
|
||||
- Intake is instructed to set `workflow_state = ready` through typed Ticket tools after materializing a Ticket.
|
||||
- Orchestrator treats `queued` as schedulable and moves to `inprogress` when starting.
|
||||
|
||||
Validation after merge:
|
||||
- `cargo test -p ticket workflow --lib`
|
||||
- `cargo test -p ticket`
|
||||
- `cargo test -p tui workspace_panel --lib`
|
||||
- `cargo test -p tui multi_pod --lib`
|
||||
- `cargo test -p yoi panel`
|
||||
- `cargo test -p yoi ticket`
|
||||
- `cargo test -p pod ticket --lib`
|
||||
- `cargo test -p client ticket_role`
|
||||
- `cargo check --workspace --all-targets`
|
||||
- `cargo fmt --check`
|
||||
- `git diff --check HEAD~1..HEAD`
|
||||
- `cargo build -p yoi`
|
||||
- `target/debug/yoi ticket doctor`
|
||||
- `nix build .#yoi --no-link --print-out-paths`
|
||||
|
||||
External review approved after transition-graph enforcement was added.
|
||||
|
||||
|
||||
---
|
||||
Reference in New Issue
Block a user