feat!: RC1 gate — remove vendor/RUM enums, add semconv versioning policy - #57
Merged
Conversation
…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>
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>
Member
Author
|
Test coverage is at 100%. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The agreed 1.0.0-rc.1 gate:
lib/src/api/semantics/rum.dartis 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-@Deprecatedin 1.0.0-beta.10 with this removal announced. They are not OTel semantic conventions and do not belong in the API;flutterrific_opentelemetrydefines its own Flutter conventions for what the registry does not yet cover. The API package now contains only registry conventions.tool/semconv/generate.sh --check.1.0.0-rc.1-wipsotool/release.dartreleases1.0.0-rc.1.Verification
dart analyze --fatal-infosclean,dart formatcleandart test: 1059 passed (VM)dart test -p chrome -c dart2js,dart2wasm: 2114 passedDownstream
flutterrific_opentelemetrydefines its own conventions for these before adopting rc.1 (tracked alongside thedartasticApiKey/tenantIdforwarding removal).🤖 Generated with Claude Code