Skip to content

feat(android): Report cellular network technology - #6827

Open
alwx wants to merge 1 commit into
mainfrom
alwx/feature/4256
Open

alwx wants to merge 1 commit into
mainfrom
alwx/feature/4256

Conversation

@alwx

@alwx alwx commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

📢 Type of change

  • New feature

📜 Description

Events now report the generation of the cellular network technology in device.connection_effective_type, for example 4g or 5g.

Both native SDKs produce the field, so this SDK only has to pass it on. iOS already does, because sentry-cocoa 9.30.0 puts connection_type and connection_effective_type into the extra context that fetchNativeDeviceContexts merges into the device context. Android needs sentry-java 8.60.0, where DeviceInfoUtil sets both fields and serializeScope returns them.

The Android version bump is still missing, because sentry-java 8.60.0 is not released yet. This pull request stays a draft until the bump is in.

💡 Motivation and Context

Closes #4256

💚 How did you test it?

  • A unit test in devicecontext.test.ts makes sure that both fields reach the event device context from the native layer.

📝 Checklist

  • I added tests to verify changes.
  • No new PII added or SDK only sends newly added PII if sendDefaultPII is enabled.
  • I updated the docs if needed.
  • All tests passing.
  • No breaking changes.

The Android SDK reports the generation of the cellular network
technology in device.connection_effective_type from sentry-java
8.60.0. The field reaches events through serializeScope, so this
SDK only has to bundle that version.

iOS already reports the field, because sentry-cocoa 9.30.0 puts it
into the extra context that fetchNativeDeviceContexts merges into
the device context.

The tests guard the path from the native layer to the event. The
version bump follows when sentry-java 8.60.0 is released.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown
Contributor

Semver Impact of This PR

⚪ None (no version bump detected)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


  • feat(android): Report cellular network technology by alwx in #6827
  • fix(ios): Prevent crash when initialized with an invalid DSN by antonis in #6825
  • chore(core): Resolve non-actionable TODOs by antonis in #6826
  • chore(core): resolve stale TODO comments by antonis in #6819
  • fix(profiling): Populate Hermes runtime version on JS profiles by antonis in #6817

🤖 This preview updates automatically when you update the PR.

@github-actions

github-actions Bot commented Oct 2, 2026

Copy link
Copy Markdown
Contributor
Fails
🚫 Pull request is not ready for merge, please add the "ready-to-merge" label to the pull request
Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against 23fd75c

@alwx
alwx marked this pull request as ready for review October 2, 2026 12:52
@alwx

alwx commented Oct 2, 2026

Copy link
Copy Markdown
Contributor Author

@antonis this one is practically ready and will work automatically once Android releases a new version (iOS released it already). I wonder what you think of this PR — there is really no work needs to be done on our side (except for a test), and I feel like we could either merge this now or wait until the next Android release. Wdyt?

@antonis antonis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🎉

Happy to approve and leave the merge to you.
I would advocate on keeping this unmerged to test on a device after the Android bump and avoid unnecessary reverts if our 8.30.0 ships before Android 8.60.0 is available.

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.

Connection Type to include Cellular Network Technology (e.g. 3G, 4G LTE, 5G)

2 participants