Comparison between arbitrary python objects can get crazy, whereas we really
only care about if the JSON state we are syncing is different. So with this change,
we store and check against the JSON state.
The new file list is always placed after the upload filename boxes. I also removed the autorefresh guards against refreshing while having an upload box since this is no longer a problem.
When there is an error reading a file, a message is shown (I could reproduce this easily by dragging a folder onto the list), added a missing "return false;" after an illegal notebook was detected, and we prevent no-name files and files starting with dots (which will not be visible in dashboard and automatically overwritten).
javascript doesn't guarantee the order of AJAX requests,
so we give `Session.delete` and `Kernel.kill` a callback signature.
Changing the kernel type calls `Notebook.start_kernel`,
which terminates the previous session, if defined,
before starting the new one.
A flag is stored, to prevent multiple simultaneous attempts to start sessions, raising a SessionAlreadyStarting Error,
preventing the spec_changed event from firing.
This is not perfect (it doesn't check against the real filesystem but the current list in the browser which may be stale) but it is better than nothing.
can happen if a message is waiting in a pipe and the web socket is closed before the message is handled.
And give ZMQChannels a nice repr with their kernel ID
Updated file upload so that the icon of the new upload item reflects if it is a file or notebook, added the ability to use the "Enter" key in the filename text box to cause the upload to happen, and make it so that the list of files refreshes immediately upon successful upload.
we recently added ws pings for keep alive,
and we can now use the longs to close dead connections.
This can apparently happen when connections are not closed cleanly,
e.g. on VPNs.
Setting ws_ping_timeout = 0 disables the ping mechanism altogether.
Sometimes for consistency or efficiency purposes, it makes sense to update
a group of properties all at once. This context manager makes this possible.
We also fix a bug where send_state was not passing the key on to get_state.
Instead of automagically instantiating a comm when it is accessed, require a call to open(). This makes the comm attribute much less magical, and hopefully more understandable.
This will immediately create a model on the javascript side when a widget is created. This means that, for example, a widget that only interacts with its model can work without "displaying" it.