-
Notifications
You must be signed in to change notification settings - Fork 61
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
Static HTML - Quarto + Python #624
Comments
I haven't tried with quarto. Do you see any errors? Maybe @cscheid can help. |
Thanks for tagging me - I see an error message in the console, specifically that a request to |
Does any widget usually work with quarto? That would be huge since there are so many any widgets now. cc @manzt |
Hey, I think there are some issues with quarto and Jupyter Widgets: manzt/anywidget#343 (comment). EDIT: hoping to have a closer look next week! |
Also, there is another dimension here (specifically with mosaic, but other widgets that rely on custom messages as well).
It would be nice if there was a "client-only mode" for the mosaic architecture in Jupyter, to embed the data and use DuckDB WASM. This would substantially increase the JS-bundle, but have a lot of benefits for this kind of use case. Maybe most simple to experiment with an environment variable first. E.g., MOSAIC_EXPERIMENTAL_EMBED=1 quarto render test.ipynb --execute The alternative would be making the renders more capable and bring the Jupyter kernel in the browser (e.g., via pyodide). Something like JupyterLite, but more minimal and for presentation. I think the Myst folks are looking into something like this (cc: @rowanc1). Could accommodate all widgets that way, but I think it's also worth exploring this more lightweight "embed" version of mosaic (since it could also be used in something like Happy to poke around with a PR post PhD :) |
Thanks for the background. I think having a client-only mode for mosaic would be nice but also having the kernel in the browser could be great (and maybe a more generic solution for similar use cases). Either way, doesn't sound like this isn't a simple bug but a larger new feature. Marked it as such. |
If you're willing to take Mosaic into OJS that works (with duckdb-wasm backend). You can use ojs_define to get Python data cleanly over to OJS at render time (ojs_define works interactively too using shiny, but I suspect this will lead to issues on duckdb/mosaic side) Newbieish Mosaic working example in Quarto using OJS (no Python or ojs_define: I preprocessed data outside of Quarto): https://calcwithdec.dev/posts/linked-visuals/ This uses the Javascript API, but you can use JSON API from OJS (might be a compile step - mosaic exposes all the pieces) edit: docs for this: https://idl.uw.edu/mosaic/api/spec/parser-generators.html |
Hi,
Really excited about the direction of this package.
I would like to display the outputs within a static html i.e. one produced with Quarto. I wasn't able to get the output to show using the Jupyter Widget. Is this use case possible? If not, is this something that could work in future?
quarto render test.ipynb --execute
test.ipynb -
The text was updated successfully, but these errors were encountered: