Skip to content

Conversation

@charleskawczynski
Copy link
Contributor

This PR adds a function, html_file, for saving the profile to a given filename. Closes #17.

@charleskawczynski charleskawczynski changed the title Ck/add html file add function for exporting an html file Sep 2, 2022
@charleskawczynski
Copy link
Contributor Author

charleskawczynski commented Sep 2, 2022

I'm now realizing that this isn't strictly necessary as I can do something similar to what's done in the test suite, by doing something like:

    trace = ProfileCanvas.view(Profile.fetch())
    html = sprint(show, "text/html", trace)
    open("flame.html", "w") do io
        print(io, html)
    end

but this is a bit more round-about compared to the proposed changes, so I'm fine with merging or using sprint to extract the output that way.

EDIT: actually, this doesn't seem to work, the window / view is severely truncated when I tried this out in TurbulenceConvection#1278.

@pfitzseb pfitzseb merged commit 3eded1a into pfitzseb:main Oct 5, 2022
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.

Allow saving profile to specific html filename

2 participants