Repository navigation
v0.5.16
Log — Fifth Domain Noun
Mecha now has five nouns: Events, Workers, Tasks, Policies, Logs.
Structured Audit Trail (internal/logs/)
- Schema V6:
logstable withINTEGER PRIMARY KEY AUTOINCREMENT, trace_id for causal grouping, typed outcome/attempt/error columns, sparse JSON detail - 14 action constants across 6 pipeline phases (webhook, match, dispatch, policy, writeback, worker)
- 5 outcome values: ok, fail, skip, retry, deny
GET /logsAPI with filters: event, task, worker, action prefix, since, limit- All detail fields redacted via
RedactSecretsbefore write - Fire-and-forget Record() — never blocks the pipeline
Package Rename — All Plural
internal/event/→internal/events/internal/worker/→internal/workers/internal/task/→internal/tasks/internal/policy/→internal/policies/internal/logs/— new (already plural)- 160 files changed, pure rename + shadowing conflict resolution
Documentation — 100% Coverage
- 183/183 exported symbols documented in go-api.md
- Logs package: types, methods, 14 action constants, 5 outcome constants
- All audit findings fixed: version refs, secrets permissions, state diagrams, Gemini annotation
Domain Model
Five nouns: Events, Workers, Tasks, Policies, Logs
Pipeline: Event.arrive → Event.match → Task.create → Task.dispatch → Policy.filter → Respond
Audit: Log.record at every pipeline stage
Full Changelog: v0.5.15...v0.5.16