Closed jpomoell closed 2 years ago
Thanks for a feedback. I can reproduce this error. It is in save here:
this.cameraChangeId = this.K3DInstance.on(this.K3DInstance.events.CAMERA_CHANGE, (control) => {
if ((new Date()).getTime() - self.model.lastCameraSync > 200) {
self.model.lastCameraSync = (new Date()).getTime();
self.model.save('camera', control, { patch: true });
}
});
I don't know why I cannot save this model. For sure we can wrap it in K3D with try/catch to avoid stoping whole process. I will check that and return with outcome!
ps. or even: or even: if (self.model._comm_live) {
Yup! That solves the problem :)
Sorry, I should have studied the documentation more carefully.
I am using k3d in a setting where the user can interact with the k3d.plot via an interface built using ipywidgets. While everything works great in the notebook, I would also like to embed snapshots in html pages, which is causing issues. As an example, in the following
the generated html file shows the plot and the checkbox works. However, the usual mouse interaction does not work, e.g. rotating the view does not work. When trying to rotate the view, the browser console reports
embed-amd.js:69 Uncaught Syncing error: no comm channel defined
Creating a snapshot of only the plot using
plot.get_snapshot()
works, but I am unsure how to get both the widgets and the plot embedded at the same time. Any help would be very much appreciated!