Skip to content

feat!: RC1 gate — remove vendor/RUM enums, add semconv versioning policy - #57

Merged
michaelbushe merged 9 commits into
mainfrom
feat/rc1-vendor-purge
Jul 18, 2026
Merged

feat!: RC1 gate — remove vendor/RUM enums, add semconv versioning policy#57
michaelbushe merged 9 commits into
mainfrom
feat/rc1-vendor-purge

Conversation

@michaelbushe

@michaelbushe michaelbushe commented Jul 18, 2026

Copy link
Copy Markdown
Member

What

The agreed 1.0.0-rc.1 gate:

  1. Remove the deprecated vendor/RUM enumslib/src/api/semantics/rum.dart is deleted along with its tests. All 15 enums (AppLifecycleStates, AppLifecycleSemantics, AppStartType, AppInfoSemantics, DeviceSemantics, BatterySemantics, NavigationSemantics, InteractionType, InteractionSemantics, PerformanceSemantics, ErrorSemantics, NetworkSemantics, RumSessionView, NavigationAction, LifecycleState) were wholesale-@Deprecated in 1.0.0-beta.10 with this removal announced. They are not OTel semantic conventions and do not belong in the API; flutterrific_opentelemetry defines its own Flutter conventions for what the registry does not yet cover. The API package now contains only registry conventions.
  2. Semantic-conventions versioning policy in VERSIONING.md: within a major, registry regenerations are additive and deprecating only; registry changes that rename/remove generated identifiers or change emitted strings batch into the next major; spec-fidelity string corrections are bug fixes with a CHANGELOG wire-format table (precedent: beta.10). Regeneration freshness is verified with tool/semconv/generate.sh --check.
  3. Version → 1.0.0-rc.1-wip so tool/release.dart releases 1.0.0-rc.1.

Verification

  • dart analyze --fatal-infos clean, dart format clean
  • dart test: 1059 passed (VM)
  • dart test -p chrome -c dart2js,dart2wasm: 2114 passed
  • Pre-push coverage gate (≥92%) passed

Downstream

flutterrific_opentelemetry defines its own conventions for these before adopting rc.1 (tracked alongside the dartasticApiKey/tenantId forwarding removal).

🤖 Generated with Claude Code

michaelbushe and others added 3 commits July 18, 2026 15:52
…for RC1

- Delete lib/src/api/semantics/rum.dart (15 vendor/RUM enums deprecated
  in 1.0.0-beta.10) and their tests; the API package now contains only
  OpenTelemetry registry conventions. Future home: flutterrific_opentelemetry.
- Add the semantic-conventions versioning policy to VERSIONING.md:
  within a major, registry regenerations are additive and deprecating
  only; identifier/wire-affecting registry changes batch to majors;
  spec-fidelity string corrections are minor-release fixes with a
  CHANGELOG wire-format table.
- Version to 1.0.0-rc.1-wip.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- app_lifecycle_semconv_test: device.app.lifecycle event,
  android.app.state / ios.app.state and their values (replaces
  lifecycle_state_test).
- app_screen_semconv_test: app.screen.* / app.widget.* attributes and
  click events — the nearest convention to the removed NavigationAction,
  which has no registry equivalent (replaces navigation_action_test).
- mobile_semconv_test: registry equivalents of the removed RUM enum
  keys — device.*, session.*, network.connection.type, error.type,
  service.*, app crash/jank (replaces rum_semantics_test).
- Format semconv_invariants_test.dart (fixes the CI analyze job's
  format check on this branch).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
flutterrific_opentelemetry owns and defines Flutter conventions for
what the registry does not yet cover (navigation actions, Flutter
lifecycle mapping); nothing 'stays vendor'.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
michaelbushe and others added 6 commits July 18, 2026 17:51
Stale coverage JSON from earlier runs was merged by format_coverage,
corrupting line references (genhtml range errors) and deflating totals.
Wipe coverage/ first, and cd to the repo root so the script behaves the
same wherever it is invoked from.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Entity enums' only executable line is the toString arrow; the entity
invariant read .name/.identifying/.descriptive but never called
toString(), leaving semconv/entities/ at 0% line coverage while every
other semconv directory was at 100%. Asserting toString == name (the
same contract the attribute/metric/event invariants already assert)
brings entities to 100% and overall lib/ coverage from 93.3% to 95.3%.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- Cover the seven metric-instrument convenience methods, the named
  loggerProvider path, and the debug log emitted when initialize()
  replaces the uninitialized no-op factory. otel_api.dart 89.7% -> 100%;
  lib/ overall 96.3%.
- Codecov uploads have failed on every main run since branch protection
  was enabled ('Token required because branch is protected'), decaying
  the README badge to 'unknown'. Pass CODECOV_TOKEN and move to
  codecov-action@v5. The CODECOV_TOKEN repo secret must be added for
  uploads to resume.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Ok is the default; setting it explicitly reinforces a bad practice.
Only Error needs an explicit setStatus. Note this on the first README
example.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Tests for the previously untested surfaces: observable-instrument
callback registration, histogram record/boundaries, meter and tracer
equality, span getters and mutators (addEvents, addLink, addSpanLink,
setDateTimeAsStringAttribute), recordException with a throwing
toString, factory-gone StateErrors, ID byte-length validation,
TraceState 32-entry eviction, Context.withSpanContext trace-change
rejection, ContextKey surface, the APISpanCreate/SpanLinkCreate guards,
and the native platform stubs.

Driven out by the tests:
- fix: Attributes.of threw TypeError on untyped lists; attrsFromMap now
  element-checks like fromJson (mixed numerics promote to double,
  unsupported lists warn and are ignored).
- APIObservableResult becomes an abstract interface: its API-side
  implementation was unconstructible dead code; SDKs implement it.
- Removed unreachable defensive code: MeterProvider shutdown/forceFlush
  try/catch over non-throwing bodies, and the Attribute null-element
  list guard that sound null safety already rules out.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The last eight lines: baggage empty-name warn, fromJson untyped string
lists, the no-SDK parent-span context pass-through, and the
OTelFactory.isAPIFactory default. Removed two more pieces of dead
defensive code the tests proved unreachable: the APISpan constructor's
parent validation (duplicated verbatim in APISpanCreate.create, its
sole caller) and TracerProvider.shutdown's try/catch over a
non-throwing body.

CONTRIBUTING.md now asks contributors to join the #otel-dart channel on
the CNCF Slack.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@michaelbushe

Copy link
Copy Markdown
Member Author

Test coverage is at 100%.

@michaelbushe
michaelbushe merged commit 6376e25 into main Jul 18, 2026
6 checks passed
@michaelbushe
michaelbushe deleted the feat/rc1-vendor-purge branch July 18, 2026 17:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant