62 lines
2.6 KiB
Markdown
62 lines
2.6 KiB
Markdown
# MACP Phase 2A Scratchpad
|
|
|
|
## Session Start
|
|
|
|
- Session date: 2026-03-27 / 2026-03-28 America/Chicago
|
|
- Branch: `feat/macp-phase2a`
|
|
- Issue: `#10`
|
|
- Objective: build the MACP event bridge and notification system from `docs/tasks/MACP-PHASE2A-brief.md`
|
|
|
|
## Budget
|
|
|
|
- Budget mode: inferred working budget
|
|
- Estimate: medium
|
|
- Token strategy: keep context narrow to event-bridge files, verify with targeted temp-repo tests, avoid unnecessary parallel deep dives
|
|
|
|
## Requirements Notes
|
|
|
|
- PRD updated to Phase 2A before coding
|
|
- TDD requirement: not mandatory for this feature work; targeted verification is sufficient because this is new observability functionality rather than a bug fix or auth/data-mutation change
|
|
- Documentation gate applies because developer-facing behavior and CLI surface change
|
|
|
|
## Assumptions
|
|
|
|
1. ASSUMPTION: corrupt or partial lines should be logged and skipped while still advancing the cursor past the offending line, preventing permanent replay loops.
|
|
2. ASSUMPTION: `mosaic macp watch` may run without webhook delivery enabled and should still process events plus persist cursor state.
|
|
3. ASSUMPTION: Discord formatting remains a pure formatting layer; no outbound Discord transport is part of Phase 2A.
|
|
|
|
## Plan
|
|
|
|
1. Update PRD/TASKS and create the Phase 2A issue/scratchpad.
|
|
2. Implement watcher, webhook adapter, formatter, and CLI wiring.
|
|
3. Update developer docs and sitemap.
|
|
4. Run baseline and situational verification.
|
|
5. Run independent code review, remediate findings, then commit/push/PR/merge/CI/issue-close.
|
|
|
|
## Progress Log
|
|
|
|
- 2026-03-28T02:02:38Z: Created provider issue `#10` for Phase 2A using Mosaic wrapper with Gitea API fallback.
|
|
- 2026-03-28T02:02:38Z: Replaced stale Phase 1 PRD/TASKS planning state with Phase 2A scope and tracking.
|
|
|
|
## Verification Plan
|
|
|
|
| Acceptance Criterion | Verification Method | Evidence |
|
|
|---|---|---|
|
|
| AC-1 watcher polls new events and respects cursor | Temp events file + repeated `poll_once()` / CLI runs | pending |
|
|
| AC-2 webhook delivery retries and succeeds/fails cleanly | Local stdlib echo server capture | pending |
|
|
| AC-3 Discord formatting covers required event types | Targeted Python formatter check | pending |
|
|
| AC-4 `mosaic macp watch --once` runs cleanly | CLI one-shot execution in temp repo | pending |
|
|
| AC-5 cursor persistence handles repeat run and truncation | Temp repo repeated runs with truncated file scenario | pending |
|
|
|
|
## Tests Run
|
|
|
|
- pending
|
|
|
|
## Review Notes
|
|
|
|
- pending
|
|
|
|
## Risks / Blockers
|
|
|
|
- Potential git wrapper friction in worktrees for PR creation/merge steps; if it recurs, capture exact failing command and stop per Mosaic contract.
|