Skip to content

Add some console utilities to retrieve the current profile and save it to disk#5105

Merged
julienw merged 6 commits into
firefox-devtools:mainfrom
julienw:add-console-to-retrieve-profile
Aug 30, 2024
Merged

Add some console utilities to retrieve the current profile and save it to disk#5105
julienw merged 6 commits into
firefox-devtools:mainfrom
julienw:add-console-to-retrieve-profile

Conversation

@julienw

@julienw julienw commented Aug 30, 2024

Copy link
Copy Markdown
Contributor

No description provided.

@codecov

codecov Bot commented Aug 30, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 20.93023% with 34 lines in your changes missing coverage. Please review.

Project coverage is 88.42%. Comparing base (ac4ae1f) to head (6a01689).
Report is 7 commits behind head on main.

Files with missing lines Patch % Lines
src/utils/window-console.js 8.33% 19 Missing and 3 partials ⚠️
src/actions/receive-profile.js 33.33% 12 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5105      +/-   ##
==========================================
- Coverage   88.48%   88.42%   -0.07%     
==========================================
  Files         304      304              
  Lines       27523    27549      +26     
  Branches     7444     7450       +6     
==========================================
+ Hits        24355    24360       +5     
- Misses       2943     2961      +18     
- Partials      225      228       +3     

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

@canova canova left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good to me with the content type fixed, thanks!

Comment thread src/utils/window-console.js Outdated
};

target.saveToDisk = async function (
rawGeckoProfile: MixedObject | ArrayBuffer,

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I guess this could any object as well like you said in Matrix and not only rawGeckoProfile. Maybe rename this to reflect that?

Comment thread src/utils/window-console.js Outdated
: JSON.stringify(rawGeckoProfile);

const blob = new Blob([arrayBuffer], {
type: 'application/octet-strea',

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
type: 'application/octet-strea',
type: 'application/octet-stream',

@julienw julienw force-pushed the add-console-to-retrieve-profile branch from 3c7ad63 to 1a3b9da Compare August 30, 2024 12:23

@canova canova left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good to me, but it looks like you amended the naming changes to the wrong commit :) (the test changes one) + with the nits I mentioned before

@julienw julienw force-pushed the add-console-to-retrieve-profile branch from 1a3b9da to 6a01689 Compare August 30, 2024 13:49
@julienw julienw merged commit 6d19e07 into firefox-devtools:main Aug 30, 2024
canova added a commit that referenced this pull request Sep 5, 2024
[Tatsuyuki Ish] Fix type error in getPagesMap (#5063)
[Nazım Can Altınova] [Tab selector 1] Add a redux state for the tab
filter (#5072)
[Markus Stange] Remove a test for the inverted stack chart. (#5075)
[Markus Stange] Add an inverted tree test for getSamplesSelectedStates
and getTreeOrderComparator (#5076)
[Nazım Can Altınova] [Tab selector 2] Extract the page data in the full
view (#5073)
[Nazım Can Altınova] Do not crash on timeline hover/selection when a
profile doesn't have any samples or markers (#5086)
[Nazım Can Altınova] [Tab selector 3] Generate page information for all
tabs (#5082)
[Nazım Can Altınova] [Tab selector 4] Add a getTabToThreadIndexesMap
selector to get relevant threads per tab (#5087)
[joshuaobrien] Use the word 'archive' instead of 'zip file' in copy
(#5081)
[Markus Stange] Send a UserAgent header to the symbolication server
again (#5103)
[Julien Wajsberg] Add some console utilities to retrieve the current
profile and save it to disk (#5105)
[Nazım Can Altınova]  Add `selectedMarker` to the console APIs (#5107)
And various dependency updates.
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