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

--no-web Packaging Option #470

Open
1 task done
Delengowski opened this issue Sep 27, 2023 · 3 comments
Open
1 task done

--no-web Packaging Option #470

Delengowski opened this issue Sep 27, 2023 · 3 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@Delengowski
Copy link

Is there an existing proposal for this?

  • I have searched the existing proposals

Is your feature request related to a problem?

I have an issue utilizing the flamegraph and table output options when using memray on an airgapped system. Since the system does not have internet access, connecting to the CDNs to get the javascript is not possible and the web pages aren't fully loaded.

Describe the solution you'd like

I would like it if memray would in a --no-web packaging option that would include the necessary html/css/js files as part of memray and have the the generated html to point accordingly.

Alternatives you considered

Putting the files on the air gapped system and changing the links the html to point to the local file system path.

@Delengowski Delengowski added the enhancement New feature or request label Sep 27, 2023
@Delengowski
Copy link
Author

I'd like to take the task of making a PR for this but am a little lost on how to best go about funneling it through to ultimately make say a conda package that has this option

@godlygeek
Copy link
Contributor

godlygeek commented Feb 22, 2024

Honestly, I'm not sure what work is required here either. The biggest part of any PR here is likely figuring out exactly what files are fetched dynamically by our flame graphs as they exist today (using the developer tools of the browser should be able to get us this), and then figuring out what would be involved in vendoring a copy of those into the Memray repo. Once we have a vendored copy of each of those dependencies, it should "just" be a matter of exposing a switch that changes whether our Jinja templates include URLs linking to external resources or include the contents of those resources directly.

If we find that some of these dependencies are difficult to vendor, or have licenses that are incompatible with us vendoring them instead of loading them dynamically, this might be a nonstarter.

@sarahmonod sarahmonod added the good first issue Good for newcomers label May 20, 2024
@vitorespindola
Copy link
Contributor

vitorespindola commented May 21, 2024

Flamegraph report:

Bootstrap - MIT License - https://github.com/twbs/bootstrap/blob/main/LICENSE
JQuery - MIT License - https://jquery.org/license
Lodash - MIT License - https://lodash.com/license
plotly.js - MIT license - https://github.com/plotly/plotly.js/blob/master/LICENSE
popper.js(now Floating UI) - MIT License - https://github.com/floating-ui/floating-ui/blob/v2.x/LICENSE.md
d3 - ISC License - https://github.com/d3/d3/blob/main/LICENSE
d3-flamegraph - Apache License 2.0 - https://github.com/spiermar/d3-flame-graph/blob/master/LICENSE
d3-scale-chromatic - Not clear - https://github.com/d3/d3-scale-chromatic/blob/main/LICENSE
d3-tip - MIT License - https://github.com/caged/d3-tip/blob/master/LICENSE

Table report:

Datatables - MIT License - https://datatables.net/license/mit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants