flexx icon indicating copy to clipboard operation
flexx copied to clipboard

Dont use own websocket when in the notebook

Open almarklein opened this issue 9 years ago • 1 comments

As suggested by Min, the IPython notebook offers a "COM" object that can be used to exchange messages between Python and JS. If we'd use that, it would also work when the notebook runs not local and avoid potential firewall issues.

almarklein avatar Mar 12 '16 20:03 almarklein

I looked at this during #135, but decided against it for now, because I did not get it to work. They also seem rather undocumented at this point. Are they text only? What if I want to send binary messages later (#65)?

Also note that many of Flexx' commands to the browser are send using a display(JavaScript(...)) so the widgets also work in exported notebooks. All other communication (browser to Python, and anything arising from interaction or timers) goes through the websocket --- and can possibly be send over the COM instead.

For now, this means that flexx in the notebook only works on localhost.

almarklein avatar Jun 20 '16 15:06 almarklein