otel_mobx 0.2.0 copy "otel_mobx: ^0.2.0" to clipboard
otel_mobx: ^0.2.0 copied to clipboard

OpenTelemetry instrumentation for `package:mobx`. Wraps `runInAction` in state-management spans so MobX actions show up in your traces.

Changelog #

0.2.0 - 2026-08-10 #

Changed #

  • Attribute keys are typed constants: the state.* keys now live in a MobxSemantics enum implementing OTelSemantic (the semconv registry has no state-management convention yet; the emitted keys are unchanged).
  • Dependency floors raised to dartastic_opentelemetry ^1.1.0-beta.12 and dartastic_opentelemetry_api ^1.0.0-rc.1. The previous floors declared compatibility with API versions that predate the semconv enums this package uses and could not actually resolve-and-compile.
  • repository URL corrected to the canonical Dartastic org casing so pub.dev repository verification succeeds.

Added #

  • tracedRunInAction<T>(name, body) — runs [body] inside both a MobX action and an OTel INTERNAL span named mobx action <name>, carrying state.system=mobx, state.operation=action, state.action.name.
  • tracedRunInActionAsync<T>(name, body) — async variant.
  • Zone-scoped suppression (runWithoutMobxInstrumentation and async variant).
  • 5 tests via real MobX Observable (no mocks needed).
  • example/otel_mobx_example.dart.
0
likes
160
points
76
downloads

Documentation

API reference

Publisher

verified publisherdartastic.io

Weekly Downloads

OpenTelemetry instrumentation for `package:mobx`. Wraps `runInAction` in state-management spans so MobX actions show up in your traces.

Homepage
Repository (GitHub)
View/report issues

License

Apache-2.0 (license)

Dependencies

dartastic_opentelemetry, dartastic_opentelemetry_api, mobx

More

Packages that depend on otel_mobx