Skip to content

✨ [RUM-14340] attach sdk version to events#24

Merged
bcaudan merged 4 commits into
bcaudan/error-collectionfrom
bcaudan/sdk-version
Mar 9, 2026
Merged

✨ [RUM-14340] attach sdk version to events#24
bcaudan merged 4 commits into
bcaudan/error-collectionfrom
bcaudan/sdk-version

Conversation

@bcaudan

@bcaudan bcaudan commented Feb 27, 2026

Copy link
Copy Markdown
Collaborator

Motivation

The SDK sends telemetry events with a hardcoded version: '0.0.0'. This attaches the real SDK version from package.json to telemetry events.

Changes

  • Inject __SDK_VERSION__ build-time constant via @rollup/plugin-replace
  • Replace hardcoded version: '0.0.0' in telemetry context with __SDK_VERSION__
  • Add define entry in vitest config for unit test support
  • Assert SDK version in E2E telemetry and view scenarios
  • Document build-time constants pattern in DEVELOPMENT.md

Test instructions

  • Run the playground app and generate telemetry errors / RUM events
  • Verify in the Datadog app that sdk_version is correctly set on received events

Checklist

  • Tested locally (playground)
  • Added unit tests for this change.
  • Added e2e/integration tests for this change.
  • Updated related documentation.

@bcaudan bcaudan force-pushed the bcaudan/error-collection branch from 8c999ff to 2b01cab Compare March 2, 2026 09:08
@bcaudan bcaudan force-pushed the bcaudan/sdk-version branch from 503ca4f to 7f19e6c Compare March 2, 2026 09:10
@bcaudan bcaudan marked this pull request as ready for review March 2, 2026 09:11
@bcaudan bcaudan requested a review from cdn34dd as a code owner March 2, 2026 09:11
@bcaudan bcaudan merged commit ac61bb2 into bcaudan/error-collection Mar 9, 2026
10 checks passed
@bcaudan bcaudan deleted the bcaudan/sdk-version branch March 9, 2026 08:54
@bcaudan bcaudan mentioned this pull request Mar 26, 2026
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.

2 participants