Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Save profiles when running startLocal #95

Closed
wants to merge 3 commits into from

Conversation

nolanmar511
Copy link
Contributor

Right now, profiles are thrown away when running startLocal. With this change, profiles will be written out to files.

@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Dec 21, 2017
@codecov
Copy link

codecov bot commented Dec 21, 2017

Codecov Report

Merging #95 into master will decrease coverage by 2.6%.
The diff coverage is 9.09%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #95      +/-   ##
==========================================
- Coverage   95.77%   93.16%   -2.61%     
==========================================
  Files           6        6              
  Lines         355      366      +11     
  Branches       58       60       +2     
==========================================
+ Hits          340      341       +1     
- Misses         15       25      +10
Impacted Files Coverage Δ
ts/src/index.ts 67.6% <9.09%> (-10.73%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2a7751c...7018a7a. Read the comment docs.

@nolanmar511 nolanmar511 deleted the start-local branch December 21, 2017 19:04
@nolanmar511 nolanmar511 restored the start-local branch December 22, 2017 16:21
@nolanmar511 nolanmar511 reopened this Dec 22, 2017
@nolanmar511 nolanmar511 force-pushed the start-local branch 4 times, most recently from a54f748 to e15ec65 Compare January 8, 2018 18:14
@nolanmar511
Copy link
Contributor Author

PTAL

@@ -148,13 +151,27 @@ export async function startLocal(config: Config = {}): Promise<void> {
if (!config.disableHeap) {
const heap = await profiler.profile(
{name: 'HEAP-Profile' + new Date(), profileType: 'HEAP'});
const decodedBytes = Buffer.from(heap.profileBytes as 'string', 'base64');
fs.writeFile(

This comment was marked as spam.

This comment was marked as spam.

@aalexand
Copy link
Contributor

aalexand commented Mar 6, 2018

Should this PR be closed or submitted?

@nolanmar511
Copy link
Contributor Author

I think I'll close this. If startLocal does save profiles, it should probably be only when the user specifies this.

@nolanmar511 nolanmar511 closed this Mar 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants