feat(network-activity-plugin): show request initiator details#263
Open
draggie wants to merge 1 commit into
Open
feat(network-activity-plugin): show request initiator details#263draggie wants to merge 1 commit into
draggie wants to merge 1 commit into
Conversation
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.
Description
Adds first-class request initiator details to Network Activity. HTTP requests now capture generated stack frames immediately, resolve them through Metro symbolication asynchronously, and update the selected request with the best source-mapped app frame when available.
The Network Activity UI now includes an Initiator tab and an Initiator column, shows generated bundle locations only as fallback/debug context, and suppresses internal Metro /symbolicate requests so source-map lookups do not pollute the request list.
Related Issue
Closes #242
Context
React Native/Hermes initially reports request origins as generated Metro bundle locations, which makes the raw data hard to use. This implementation keeps request capture synchronous so rows appear immediately, then emits a follow-up initiator update once symbolication completes.
The selected initiator frame prefers source-mapped app frames and filters low-value runtime/plugin frames. The generated location remains available for debugging when source maps are unavailable. The Metro code frame is only displayed when it matches the selected source frame to avoid showing an internal interceptor frame for an app-level request.
Testing
Run network testing tool within mobile playground, enable Rozenite panel and see requests to contain new tab "Initiator" with details of where the request originated from.

Note: pnpm format:all currently fails on existing unrelated formatting issues across the repository, so formatting was verified for the files changed in this PR.