Open taiya opened 5 years ago
Clearing browser cache helped here (but no rendering is visible yet)
Clearing browser cache helped here (but no rendering is visible yet)
Not sure if I follow. Did clearing the cache make lab look normal again (and did it fix the errors in the server terminal)?
Yes, clearing the cache made it look normal, but when you execute the cell no graphics is displayed (while with notebooks it does)
How can one figure out how to resolve this?
Do you have the @jupyter-widgets/jupyterlab-manager
extension installed on lab? That tends to be a common missed point (can probably also be added to readme).
Assuming this was fixed due to lack of response, closing. If there is still something unresolved here, please comment and I'll reopen as appropriate.
Not quite, just did not have time recently. Let me try this morning
Alright, gave it another try today (on a new server):
pip install jupyter
sudo jupyter labextension install jupyter-threejs
In a jupyter notebook, the following below produces the desired output:
While in jupyter lab it is not showing anything:
Snippet used (same ipynb file for both modes)
from pythreejs import *
import numpy as np
ball = Mesh(geometry=SphereGeometry(radius=1, widthSegments=32, heightSegments=24),
material=MeshLambertMaterial(color='red'),
position=[2, 1, 0])
c = PerspectiveCamera(position=[0, 5, 5], up=[0, 1, 0],
children=[DirectionalLight(color='white', position=[3, 5, 1], intensity=0.5)])
scene = Scene(children=[ball, c, AmbientLight(color='#777777')])
renderer = Renderer(camera=c,
scene=scene,
controls=[OrbitControls(controlling=c)])
display(renderer)
What is the output of jupyter labextension list
?
(python3) /mnt/erebus/dev/cvxnet: jupyter labextension list
JupyterLab v0.35.6
Known labextensions:
app dir: /usr/local/share/jupyter/lab
@jupyterlab/celltags v0.1.4 enabled OK
@jupyterlab/git v0.5.0 enabled OK
jupyter-threejs v2.1.1 enabled OK
nbdime-jupyterlab v0.6.1 enabled OK
Ah, just saw again your note above, so looked it up and installed (I'll submit a pull request for the main readme if this is necessary)
sudo jupyter labextension install @jupyter-widgets/jupyterlab-manager
A change in the failure you get :)
Do you have any errors in the browser console (typically via Ctrl + Shift + J, or F12).
Oh yes, plenty :)
Try to upgrade your Python pythreejs package (via conda or pip), as well as updating the labextension (jupyter labextension update --all
).
pip install pythreejs --upgrade
(python3) /mnt/erebus/dev/cvxnet: pip install pythreejs --upgrade
Requirement already up-to-date: pythreejs in /home/atagliasacchi/Envs/python3/lib/python3.5/site-packages (2.1.1)
(python3) /mnt/erebus/dev/cvxnet: sudo jupyter labextension update --all
Node v11.15.0
Extension 'nbdime-jupyterlab' already up to date
Extension '@jupyterlab/git' already up to date
Extension 'jupyter-threejs' already up to date
Extension '@jupyterlab/celltags' already up to date
Extension '@jupyter-widgets/jupyterlab-manager' already up to dat
And while the above does not show versions, here they are
(python3) /mnt/erebus/dev/cvxnet: jupyter labextension list
JupyterLab v0.35.6
Known labextensions:
app dir: /usr/local/share/jupyter/lab
@jupyter-widgets/jupyterlab-manager v0.38.1 enabled OK
@jupyterlab/celltags v0.1.4 enabled OK
@jupyterlab/git v0.6.0 enabled OK
jupyter-threejs v2.1.1 enabled OK
nbdime-jupyterlab v0.6.1 enabled OK
Result of cell execution is the same:
Error displaying widget
Hmm, seems to be an issue with the latest patch release of ipywidgets (https://github.com/jupyter-widgets/ipywidgets/issues/2491). It should be fixed once that issue is resolved and released.
Fingers crossed that's the case :) Let me know when you get the chance to test.
On Wed, Jul 10, 2019, 2:52 PM Vidar Tonaas Fauske notifications@github.com wrote:
Hmm, seems to be an issue with the latest patch relelase of ipywidgets ( jupyter-widgets/ipywidgets#2491 https://github.com/jupyter-widgets/ipywidgets/issues/2491). It should be fixed once that issue is resolved and released.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/jupyter-widgets/pythreejs/issues/268?email_source=notifications&email_token=ABCF4PIT3Z35TFBCTPJYV4TP6XLSLA5CNFSM4HLW7O2KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZTLOQI#issuecomment-510048065, or mute the thread https://github.com/notifications/unsubscribe-auth/ABCF4PKR6NHR723IFK3BPJ3P6XLSLANCNFSM4HLW7O2A .
The issue with ipywidgets has been resolved, but there is now an issue with lab left to resolve this. Currently on vacation, so at least 2 weeks until I get to look at it. Note that upgrading to lab 1.0 should fix this issue.
But when you open the URL:
And in terminal, these errors appear: