Run 1: Bug Fixes
Fix card notes mapping (#815, #816), add unmark-as-printed capability (#595), verify label/breadcrumb notes mapping, and update design documentation.
Specification: Phase 1 Specification Requirements: Phase 1 Requirements Verification: Phase 1 Verification
Entry Criteria
Section titled “Entry Criteria”| # | Criterion | Verification Command | Expected Output |
|---|---|---|---|
| 1 | Operations worktree exists and builds | make -C /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/operations build | BUILD SUCCESSFUL |
| 2 | Frontend worktree exists and builds | cd /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/arda-frontend-app && npm run build | Exit 0 |
| 3 | Documentation worktree exists and builds | cd /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/documentation && make build | Complete! |
| 4 | All worktrees on correct branch | git -C /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/operations branch --show-current | jmpicnic/multi-pdf-print-and-bugs |
Artifact Specifications
Section titled “Artifact Specifications”| Artifact | Path | Format | Description |
|---|---|---|---|
| Fixed KanbanCardPrinter | operations/src/.../kanban/business/KanbanCardPrinter.kt | Kotlin | Notes field uses card.notes ?: "" without item fallback |
| UNMARK event type | operations/src/.../kanban/business/KanbanCard.kt | Kotlin | New UNMARK in KanbanCardPrintEventType enum |
| UNMARK status mapping | operations/src/.../kanban/service/PrintLifecycleImpl.kt | Kotlin | UNMARK → NOT_PRINTED in state machine |
| Unmark endpoint | operations/src/.../kanban/api/rest/KanbanCardEndpoint.kt | Kotlin | POST /kanban-card/{eId}/event/unmark |
| Frontend unmark action | arda-frontend-app/src/components/items/CardInfo.tsx | TSX | Dropdown item for PRINTED cards |
| Frontend API route | arda-frontend-app/src/app/api/arda/kanban/kanban-card/[eId]/event/unmark/route.ts | TypeScript | Proxy to backend |
| Unit tests | operations/src/test/.../kanban/ | Kotlin | Tests for notes mapping and UNMARK event |
| Updated Item Module doc | documentation/src/.../reference-data/item/index.md | Markdown | Payload mapping section verified |
| Updated Kanban Cards doc | documentation/src/.../resources/kanban-cards-module.md | Markdown | UNMARK event in print status |
| CHANGELOG entries | operations/CHANGELOG.md, arda-frontend-app/CHANGELOG.md | Markdown | Version entries for bug fixes |
Task List
Section titled “Task List”| # | Task | Persona | Depends On | Status | Acceptance Criteria |
|---|---|---|---|---|---|
| 1.1 | Fix card notes mapping in KanbanCardPrinter | back-end-engineer | — | Pending | notes = card.notes?.takeUnless { it.isBlank() } ?: "". T-P1-001 through T-P1-004 pass. |
| 1.2 | Verify label/breadcrumb notes mapping in ItemPrinter | back-end-engineer | — | Pending | Confirm notes = item.notes ?: "" is correct. T-P1-005, T-P1-006 pass. |
| 1.3 | Add UNMARK event type and status mapping | back-end-engineer | — | Pending | UNMARK added to enum. _resultPrintState(UNMARK) == NOT_PRINTED. No-op for non-PRINTED cards. T-P1-007 through T-P1-009 pass. |
| 1.4 | Expose unmark endpoint | back-end-engineer | 1.3 | Pending | POST /kanban-card/{eId}/event/unmark authenticated, tenant-scoped. T-P1-010, T-P1-011 pass. |
| 1.5 | Frontend unmark action | front-end-engineer | 1.4 (API shape) | Pending | Dropdown item visible for PRINTED cards. After unmark: NOT_PRINTED, “Print card” label. T-P1-012, T-P1-013 pass. |
| 1.6 | Update design documentation | back-end-engineer | 1.1, 1.2, 1.3 | Pending | Item Module and Kanban Cards Module docs updated. T-P1-018, T-P1-019. |
| 1.7 | Regression tests and CHANGELOG | back-end-engineer | 1.1-1.6 | Pending | make build passes operations. Jest + E2E pass frontend. CHANGELOG entries with [X.Y.Z-jmpicnic-0408] format. T-P1-014 through T-P1-017. |
Internal Dependency Graph
Section titled “Internal Dependency Graph”1.1 (fix notes) ──┐1.2 (verify notes) ┤1.3 (UNMARK enum) ─┼──→ 1.6 (update docs) ──→ 1.7 (regression + CHANGELOG) │ │ └──→ 1.4 (endpoint) ──→ 1.5 (frontend)Tasks 1.1, 1.2, 1.3 can run in parallel (independent code changes). Task 1.4 depends on 1.3. Task 1.5 depends on 1.4’s API shape (but can start with mock). Tasks 1.6 and 1.7 are sequential after all code changes.
Agent assignment: A single back-end-engineer handles 1.1-1.4, 1.6-1.7. A front-end-engineer handles 1.5. Both work in their respective worktrees — no conflicts.
Exit Criteria
Section titled “Exit Criteria”| # | Criterion | Verification Command | Expected Output |
|---|---|---|---|
| 1 | Operations builds with all tests passing | make -C .../operations build | BUILD SUCCESSFUL |
| 2 | Frontend builds | cd .../arda-frontend-app && npm run build | Exit 0 |
| 3 | Frontend Jest tests pass | cd .../arda-frontend-app && npx jest --no-coverage --watchAll=false --forceExit | All pass (1 pre-existing failure allowed) |
| 4 | Documentation builds | cd .../documentation && make build | Complete! |
| 5 | CHANGELOG updated in operations | head -5 .../operations/CHANGELOG.md | Contains jmpicnic version entry |
| 6 | CHANGELOG updated in arda-frontend-app | head -5 .../arda-frontend-app/CHANGELOG.md | Contains version entry |
| 7 | All changes committed | git -C .../operations status --short | Clean |
| 8 | All changes committed (frontend) | git -C .../arda-frontend-app status --short | Clean |
| 9 | All changes committed (documentation) | git -C .../documentation status --short | Clean or only goal.md unstaged |
Note: The documentation repository CHANGELOG is updated once at the end of the project (before the documentation PR), not per-run.
Agent Prompt Templates
Section titled “Agent Prompt Templates”Back-End Engineer — be-bug-fixes
Section titled “Back-End Engineer — be-bug-fixes”You are implementing bug fixes for the Arda printing pipeline in the operations repository at /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/operations.
Read the specification at /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/documentation/src/content/docs/roadmap/in-progress/multi-pdf-print-and-bugs/phase-1-bug-fixes/specification.md and implement Tasks 1.1, 1.2, 1.3, 1.4, 1.6, and 1.7. Use mode: "bypassPermissions".
Key decisions:
- UNMARK on non-PRINTED cards is a no-op (idempotent)
- Endpoint path:
POST /kanban-card/{eId}/event/unmark(consistent with lifecycle events) - CHANGELOG version format:
[X.Y.Z-jmpicnic-0408]
After code changes, update design docs in the documentation worktree at /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/documentation.
Front-End Engineer — fe-bug-fixes
Section titled “Front-End Engineer — fe-bug-fixes”You are implementing the unmark-as-printed UI action in arda-frontend-app at /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/arda-frontend-app.
Read the specification at /Users/jmp/code/arda/projects/multi-pdf-print-and-bugs-worktrees/documentation/src/content/docs/roadmap/in-progress/multi-pdf-print-and-bugs/phase-1-bug-fixes/specification.md and implement Task 1.5.
Key decisions:
- Unmark action is a dropdown menu item (not a separate button)
- Visible only for cards in PRINTED status
- After unmark: status shows NOT_PRINTED, button shows “Print card”
- API route:
POST /api/arda/kanban/kanban-card/{eId}/event/unmark
Handoff
Section titled “Handoff”Artifacts Consumed (from previous runs)
Section titled “Artifacts Consumed (from previous runs)”None — this is the first run.
Artifacts Produced (for subsequent runs)
Section titled “Artifacts Produced (for subsequent runs)”| Artifact | Consumer Run | Path |
|---|---|---|
| Fixed notes mapping (committed) | Run 2 | operations/src/.../kanban/business/KanbanCardPrinter.kt |
| UNMARK event type (committed) | Run 4 | operations/src/.../kanban/business/KanbanCard.kt |
| Unmark endpoint (committed) | Run 4 | operations/src/.../kanban/api/rest/KanbanCardEndpoint.kt |
| Frontend unmark action (committed) | — | arda-frontend-app/src/components/items/CardInfo.tsx |
| CHANGELOG entry | Run 2 (appends) | operations/CHANGELOG.md |
Copyright: (c) Arda Systems 2025-2026, All rights reserved
Copyright: © Arda Systems 2025-2026, All rights reserved