Skip to content

Fix from-url with binary profiles#6072

Open
mstange wants to merge 1 commit into
firefox-devtools:mainfrom
mstange:push-luvqvlzstyvt
Open

Fix from-url with binary profiles#6072
mstange wants to merge 1 commit into
firefox-devtools:mainfrom
mstange:push-luvqvlzstyvt

Conversation

@mstange
Copy link
Copy Markdown
Contributor

@mstange mstange commented May 29, 2026

Main | Deploy preview


The function _extractJsonFromResponse was assuming that anything that's not a zip file must be JSON. However this means that from-url wasn't working with binary profile formats (json-slabs, simpleperf, art trace).

This PR makes it so that fetchProfile no longer calls JSON.parse, but instead the interpretation of the bytes happens entirely within unserializeProfileOfArbitraryFormat.

@mstange mstange requested a review from canova May 29, 2026 20:02
@codecov
Copy link
Copy Markdown

codecov Bot commented May 29, 2026

Codecov Report

❌ Patch coverage is 83.33333% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 83.77%. Comparing base (52f65d8) to head (7eaad98).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
src/actions/receive-profile.ts 66.66% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6072      +/-   ##
==========================================
- Coverage   83.77%   83.77%   -0.01%     
==========================================
  Files         329      329              
  Lines       34559    34543      -16     
  Branches     9574     9665      +91     
==========================================
- Hits        28952    28938      -14     
+ Misses       5178     5176       -2     
  Partials      429      429              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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