Skip to content

feat: add structured logging and tracing spans to act refactor validation #125

Description

@coderabbitai

Summary

PR #102 introduces a validation gate for weaver act refactor (provider, refactoring, and required flags), but no observability infrastructure accompanies it. Operators and developers have no insight into validation failures in production or test environments beyond the returned error message.

Work Required

  • Add tracing spans around the validation flow in crates/weaverd/src/dispatch/act/refactor/
  • Emit structured debug!/warn! events at each validation decision point (e.g. missing flag detected, unsupported provider received)
  • Introduce failure-type metrics covering at minimum:
    • missing_required_flags
    • unsupported_provider
    • unsupported_refactoring
    • malformed_trailing_arguments
  • Ensure new instrumentation does not alter the existing DispatchError contract or JSONL transport envelope

Background

Raised as an out-of-scope follow-up from PR #102.
Requested by @leynos.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions