Closed jlumpe closed 3 years ago
This is working as expected. JupyterLab doesn't expose its internals via global variables the way that the classic notebook does, so it's not possible to render WebIO as vanilla HTML.
The underlying error may be expected in this condition, but I don't think that's reflected in the error message. It makes it seem like the problem is that WebIO has not been installed correctly. "WebIO Not Detected" is the same message shown when importing WebIO without having the jupyterlab extension installed and it even links to the same troubleshooting page, despite this being a totally separate issue (I spent a lot of time troubleshooting thinking my installation was messed up due to this error).
The message should say something about this being expected in Jupyterlab and to use application/vnd.webio.node+json
instead of text/html
.
You're welcome to open a PR to add this and/or add a section in the docs. I think that message links to a troubleshooting docs page, so it could be added there.
Sure, I can do that. I'm not familiar enough with the Jupyterlab front end stuff to really know what's being checked in those if statements, though. It looks like the 2nd condition is the only one that actually displays the data. The first one just logs the message "Jupyter WebIO extension detected, not mounting." As far as I can tell that one should probably be displayed in the HTML as well. I'm just not really sure what the messages should be since I can't tell what conditions are triggering them.
The bug
display("text/html", node::Node)
in Jupyterlab using IJulia results in a red box displaying the following error message:display(node)
anddisplay("application/vnd.webio.node+json", node)
work as intended.git blame
shows the relevant lines were last updated over a year ago (99b5d78c), so I'm wondering if this method became obsolete and was never removed.Context