Skip to content
This repository was archived by the owner on Apr 14, 2026. It is now read-only.

feat(logging): add Riverpod state observability via ProviderObserver (6/6)#245

Draft
runyaga wants to merge 1 commit intomainfrom
feat/otel-provider-observer
Draft

feat(logging): add Riverpod state observability via ProviderObserver (6/6)#245
runyaga wants to merge 1 commit intomainfrom
feat/otel-provider-observer

Conversation

@runyaga
Copy link
Copy Markdown
Collaborator

@runyaga runyaga commented Feb 8, 2026

Summary

  • Adds LoggingProviderObserver that pipes all Riverpod state transitions into soliplex_logging at debug level
  • Adds Loggers.state logger for the State domain
  • Wires observer into ProviderScope in runSoliplexApp
  • Includes worktree-safe wrapper scripts for pre-commit hooks (same as PR fix(hooks): add dart fix step and worktree-safe wrappers #234)

Changes

  • lib/core/logging/logging_provider_observer.dart: New base class implementing Riverpod 3 ProviderObserver API — logs provider.name: newValue via Loggers.state.debug()
  • lib/core/logging/loggers.dart: Add State logger
  • lib/run_soliplex_app.dart: Wire LoggingProviderObserver into ProviderScope.observers
  • test/core/logging/logging_provider_observer_test.dart: Unit tests for named and unnamed provider logging
  • scripts/: Worktree-safe wrapper scripts for dart format and flutter analyze
  • .pre-commit-config.yaml: Use wrapper scripts instead of bare commands

Why

Closes the last major observability gap: LLMs (via get_app_logs) and integration tests (via TestLogHarness / MemorySink) can now see all Riverpod state changes alongside HTTP traffic, auth events, and AG-UI lifecycle logs.

Test plan

  • flutter analyze — 0 issues
  • Unit tests pass (2 tests: named provider, unnamed provider)
  • Pre-commit hooks pass (dart format + flutter analyze)

…(6/6)

Pipes all Riverpod provider state transitions into soliplex_logging
at debug level. This gives LLMs (via get_app_logs) and integration
tests (via TestLogHarness / MemorySink) full visibility into provider
state changes — closing the last major observability gap.

- Add LoggingProviderObserver (base class, Riverpod 3 API)
- Add Loggers.state logger for State domain
- Wire observer into ProviderScope in runSoliplexApp
- Add unit tests verifying named and unnamed provider logging
- Add worktree-safe wrapper scripts for pre-commit hooks
@runyaga runyaga self-assigned this Feb 11, 2026
@runyaga runyaga marked this pull request as draft February 11, 2026 16:21
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants