When to use
- •You changed ticket CLI output/formatting (commonly
src/agent_loom/ticket/cli.py). - •You changed ticket core semantics that affect displayed UX (commonly
src/agent_loom/ticket/core.py). - •You added/changed ticket UX tests.
Goal
Keep ticket UX deterministic and regression-tested.
Steps
- •
Define the contract
- •Decide what must remain stable (headers, ordering, required fields, wording invariants).
- •Avoid asserting on irrelevant whitespace unless whitespace is the contract.
- •
Make output deterministic
- •Use explicit ordering for lists/fields.
- •Avoid dict/set iteration order as an implicit contract.
- •
Add/update focused tests
- •Prefer
tests/test_ticket_ux.pyfor UX/output contracts. - •Assert on stable invariants (or snapshot only if the full text is the contract).
- •Prefer
- •
Verification
- •Run
lsp_diagnosticson touched files. - •Run
uv run ruff check .. - •Run
uv run pytest tests/test_ticket_ux.py(then expand if needed).
- •Run
Common failure modes
- •Output changes without tests (silent UX regressions).
- •Order-dependent output breaks under minor refactors.
- •Tests snapshot too much nondeterministic content.
Manual notes
This section is preserved when the skill is updated. Put human notes, caveats, and exceptions here.