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

offline=True in embed_html failing to save required file js/jupyter-threejs.js #192

Open
GenevieveBuckley opened this issue Oct 21, 2018 · 4 comments · May be fixed by #198
Open

offline=True in embed_html failing to save required file js/jupyter-threejs.js #192

GenevieveBuckley opened this issue Oct 21, 2018 · 4 comments · May be fixed by #198
Labels
bug good first issue If you'd like to contribute with a not to complex problem

Comments

@GenevieveBuckley
Copy link
Contributor

The offline=True kwarg in ipyvolume.embed.embed_html() is failing to save the file at https://unpkg.com/jupyter-threejs@2.0.1/dist/index.js locally as js/jupyter-threejs.js

Copying that file manually into js/jupyter-threejs.js fixes the issue and allows offline viewing.

I'm using ipyvolume installed from master branch: 0.5.2-dev.1

@GenevieveBuckley
Copy link
Contributor Author

It's possible this is wholly or partially resolved by the offline_embed branch here: https://github.com/maartenbreddels/ipyvolume/tree/offline_embed

@maartenbreddels maartenbreddels added bug good first issue If you'd like to contribute with a not to complex problem labels Oct 30, 2018
@maartenbreddels
Copy link
Collaborator

That branch is old, I'll remove it. Seems like a legit bug.

@GenevieveBuckley
Copy link
Contributor Author

Maybe related: I was wondering if it would be of general use to have a no dependencies option for the offline html? It'd be useful in situations where you write many html files to the same location, and care about how fast you can write them to disk.
(This is something we're doing at the moment, overwriting a single file with new data, and I think it'd speed up the responsiveness quite a bit if it didn't re-download every dependency each time.)

@maartenbreddels
Copy link
Collaborator

Yes, a cache would be nice, I think though it should (optionally) check the CDN for the right version, and if not it should update it. My guess is that the request package can do this. I also hate that it downloads everything every time. It can also do a hardlink to the cached file (for non-windows users).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug good first issue If you'd like to contribute with a not to complex problem
Projects
None yet
2 participants