-
Notifications
You must be signed in to change notification settings - Fork 553
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
Cell with HTML page renders incorrectly in NBViewer #316
Comments
I attempted to replicate your problem with little luck. It seems WebGL support is not so good on Linux with 3+ year old graphics card, haha. When I did get it to render the main render area expanded downward continually until the browser crashed. Do you perhaps have an example of this bug that doesn't use WebGL? |
The problem you are describing is exactly the one that I experienced On (Aug-21-14|11:39), Isaac Cook wrote:
|
Just updated to the latest Chrome which seems to have helped quite a bit (doesn't crash anymore...). To clarify what I'm getting:
This seems to be more related to different HTML bounding boxes between the html view mode of ipython and the notebook editing mode. Might also be a security thing? Possibly some JS isn't getting executed on the exported version since it's untrusted? Either way, I'm not sure it's something that's within the viewers scope to resolve since these are both mechanisms of IPython itself. |
Thanks for testing this out @icook! That notebook was working a few weeks ago, in any case I just created a new notebook that renders correctly when running IPython locally i. e. this time it actually shows the content in the cell at a usable size: However when I go to nbviewer the content expands increasingly, see this link and the animated gif below: If you see in the notebook, the way that I'm rendering the code is by using: from IPython.display import HTML, display
display(HTML(x), metadata=dict(isolated=True)) My guess is that the |
O_o Nice bug. Sorry, we are all more or less overwhelmed, and indeed it is not wrapped in a iframe |
Can you try running nbconvert on your notebook manually to see how the produced HTML behaves?
|
Sadly the produced HTML presents the same problem as the nbviewer render. The result of the conversion can be found here. |
I've taken a whack at solving this, but the solution is incomplete. (https://github.com/icook/ipython/commits/316). Height doesn't seem to adjust, and I'm getting some JS errors from the Emperor demo when rendered in this way. I tried to basically mimic what the live viewer does (https://github.com/icook/ipython/blob/master/IPython/html/static/notebook/js/outputarea.js#L340). I'll keep working on it as time permits. |
Awesome!! 👍 |
Friendly ping, this is still an issue :'( |
Please, can someone provide a current link to an .ipynb in an anonymous (and therefore immutable) gist, broken with this bug, that isn't broken in other ways (webgl, missing assets)? We don't have phantom/casper tests yet, but we can add them if we have something reproducible. |
Sorry for that, I was pointing to a constantly changing URL for the I apologize for that! Let us know if there's anything we can help with. On (Mar-07-15|14:34), bollwyvl wrote:
|
I have an object that displays some HTML when called from an IPython notebook using the
_repr_html_
method. The result is as expected in the IPython notebook, however when I view file from nbviewer, some weird things happen.Problematic notebook:
http://nbviewer.ipython.org/gist/ElDeveloper/24a383b778943a187966
You should be able to download this file and view the correct output in your machine.
The text was updated successfully, but these errors were encountered: