jp_proxy_widget icon indicating copy to clipboard operation
jp_proxy_widget copied to clipboard

Opening a jp_proxy_widget in a separate JupyterLab window

Open psychemedia opened this issue 4 years ago • 8 comments

It would be really useful to be able to open a jp_proxy_widget in a new JupyterLab output window. This would provide a simple mechanism for then creating JupyterLab apps running in their own window as simple jp_proxy_widget wrapped Javascript applications.

Related issue: https://github.com/jupyterlab/jupyterlab/issues/3692

I had wondered in the past if `jupyterlab-sidecar' might offer an alternative route (or suggest some plumbing that would allow a widget to be opened directly in a new output window) but it appears to be a stale project?

psychemedia avatar Oct 17 '20 15:10 psychemedia

Yes, I think this would be nice for any complex widget. Maybe suggest or ask about it with the ipywidgets implementors? I actually was under the impression that this was possible already (but I haven't actually seen it).

AaronWatters avatar Nov 13 '20 21:11 AaronWatters

Just revisiting JupyterLab again again (I can't really keep up with its version changes), and jp_proxy_widget seems not to work in any of the MyBinder environment's I've tried, raising a "model can't be found" message if I try to load run even the code in simple hello-word demo notebook.

Just me or has JupyterLab updates broken things in JupyterLab context again?

psychemedia avatar Mar 09 '21 15:03 psychemedia

sorry. This was my fault. I merged a pull request too quickly without checking all the test cases.

https://github.com/AaronWatters/jp_proxy_widget/commit/65159b870a62e01009e0fa14dc8bf8029e089168

That should fix the problem. Please let me know if it doesn't or if you see other issues. Thanks!

AaronWatters avatar Mar 09 '21 16:03 AaronWatters

I just ran the repo in MyBinder and still get the issue?

image

psychemedia avatar Mar 09 '21 18:03 psychemedia

&^%$

I think I fixed it.

I had to bump a version number in package.json.

I wish they'd stop doing this.... it happens about once every 6 months....

Please verify that it fixes it for you too. I will leave the pull request commented for now (even though it is probably innocent).

https://github.com/AaronWatters/jp_proxy_widget/commit/e93b2644d5b8ea8e8319cea46ecc67a4106265a4

AaronWatters avatar Mar 09 '21 20:03 AaronWatters

Seems to work fine now from a Binderised version of your repo, but not from sidecar Binder? And sidecar which I did have working in some Binderised environment somewhere today is now not working...

I have wasted so much time going nowhere trying to do anything ever in JupyterLab ;-)

I am going to park trying to get my widgets working in JupyterLab for another 3 months again, I think! JupyterLab seems to continue to be a really brittle dependency hell environment. And the install JupyterLab rebuilds still take forever.... I hate it, hate it, hate it!;-)

psychemedia avatar Mar 09 '21 22:03 psychemedia

I need to start revisiting this idea again (running a jp_proxy_widget js app in a "torn off" or separate window or sidecar widget. Do you have or know of any widgets that demo this working?

psychemedia avatar Jul 11 '21 18:07 psychemedia

Just as a placeholder, I note that at some point in the past, sidecar and jp_proxy_widget did play nice for a period and you could display a jp_proxy_widget wrapped widget in a sidecar panel: https://blog.ouseful.info/2021/09/22/getting-nbev3devsim-running-in-jupyterlab/

I'm not sure what happened if you tried to open sidecar panels in separate notebooks in the same JupyterLab view, each rendering a jp_proxy_widget? I guess there may have been an id conflict?

psychemedia avatar Jul 25 '22 18:07 psychemedia