Nathaniel Nicandro
83881bf4e0
Ensure the startup message is caught
...
Setup the necessary hooks before starting the kernel so that we can ensure that
the startup message is caught.
A short delay is also added whenever we start a channel. This was necessary for
the client to catch the startup message of a python kernel.
2018-02-07 12:08:07 -06:00
Nathaniel Nicandro
072dce7c00
Negligible changes
2018-02-04 18:22:56 -06:00
Nathaniel Nicandro
90dd699a7a
Update comments
2018-02-04 18:15:32 -06:00
Nathaniel Nicandro
ca6c2ae37a
Simplify wording of jupyter-add-callback
documentation
2018-02-04 18:06:11 -06:00
Nathaniel Nicandro
4a0cff991d
Add jupyter-ioloop-wait-until
to wait for events from ioloop subprocess
2018-02-04 17:55:47 -06:00
Nathaniel Nicandro
2ffbf74149
Flush stdout after sending all messages in ioloop subprocess
2018-02-04 17:44:27 -06:00
Nathaniel Nicandro
fe323cf623
Properly stop channels in ioloop subprocess
2018-02-04 17:43:59 -06:00
Nathaniel Nicandro
290f3a2d96
Block until channel is alive in jupyter-start-channel
for async channels
2018-02-04 17:43:20 -06:00
Nathaniel Nicandro
b72713b00c
Remove the special behavior when dropping requests
2018-02-04 17:41:48 -06:00
Nathaniel Nicandro
91da143fb1
Simplify making jupyter-request
objects when sending a message
2018-02-03 19:16:16 -06:00
Nathaniel Nicandro
80509f275c
Only allow stdin messages when the stdin channel is alive
2018-02-03 19:15:28 -06:00
Nathaniel Nicandro
019309efcd
Cleanup indentation
2018-02-03 19:14:24 -06:00
Nathaniel Nicandro
95a5cfbd74
Add jupyter--get-channel
2018-02-03 19:10:30 -06:00
Nathaniel Nicandro
91be45df3a
Add declare spec for client handlers
2018-02-03 19:06:10 -06:00
Nathaniel Nicandro
43a59ba74d
Update channel implementation
...
- Distinguish between an asynchronous channel and a synchronous one
- `jupyter-async-channel` :: Messages are sent and received through an ioloop
subprocess that the channel has access to. The
subprocess uses the `jupyter-sync-channel` for
sending and receiving messages.
- `jupyter-sync-channel` :: Messages are sent and received through a
`zmq-socket` in the current Emacs session.
- Define `jupyter-send` and `jupyter-recv` methods for channels.
- Update `jupyter-kernel-client` and ioloop interfaces to take into account
changes with channels.
2018-02-03 19:06:10 -06:00
Nathaniel Nicandro
0504bf36e0
Update documentation and comments
2018-02-03 19:06:10 -06:00
Nathaniel Nicandro
db3a73d48f
Various insignificant changes
2018-01-22 19:24:26 -06:00
Nathaniel Nicandro
5365052273
Be consistent about method arguments for request methods
...
Specifically always use keywords
2018-01-22 19:22:22 -06:00
Nathaniel Nicandro
066cc4efc0
Silence checkdoc warnings
2018-01-22 19:12:47 -06:00
Nathaniel Nicandro
9e480c7e05
Update comments
2018-01-22 19:03:34 -06:00
Nathaniel Nicandro
7f09f14128
[WIP] Remove old requests when dropping idle ones
2018-01-22 18:57:32 -06:00
Nathaniel Nicandro
66f2837d8e
Add note about subprocess lifetime
2018-01-22 18:50:04 -06:00
Nathaniel Nicandro
fa2658f168
Move custom variables to jupyter-base
from jupyter-client
2018-01-22 18:49:19 -06:00
Nathaniel Nicandro
16960cec3c
Handle shutdown_reply sent on a shell channel
2018-01-22 18:36:48 -06:00
Nathaniel Nicandro
44ff33085a
Reword doc string in jupyter--ioloop-collect-messages
2018-01-21 01:08:10 -06:00
Nathaniel Nicandro
c1b2330cc9
Handle all errors returned by zmq-poller-wait-all
...
Newer versions of `zmq-poller` signal an EAGAIN error
2018-01-21 01:04:38 -06:00
Nathaniel Nicandro
d07b9e66fe
Update to take into account changes in emacs-zmq
2018-01-20 21:39:20 -06:00
Nathaniel Nicandro
3b7a17ff34
Update documentation
2018-01-18 23:10:16 -06:00
Nathaniel Nicandro
22d79818c6
Add more debugging statements
2018-01-18 23:09:10 -06:00
Nathaniel Nicandro
42bb8bde69
Use warn
instead of error
when sanity checking
2018-01-18 23:04:22 -06:00
Nathaniel Nicandro
55bdef1b10
Add missing slots argument
2018-01-18 23:03:24 -06:00
Nathaniel Nicandro
e457ecbfa7
Add object destructors for jupyter-kernel-manager
and jupyter-kernel-client
...
These are used when an object definately needs to be destroyed. They are needed
to cleanup resources like processes and internal buffers.
2018-01-18 16:06:22 -06:00
Nathaniel Nicandro
e4c3088749
Add jupyter-inhibit-handlers
...
This removes the need for `jupyter-request-inhibit-handlers`
2018-01-17 20:34:32 -06:00
Nathaniel Nicandro
1159342c26
Make jupyter-initialize-connection
a function instead of a method
...
Initializing a connection does not change depending on the client. Or at least
it doesn't seem likely.
2018-01-17 20:15:50 -06:00
Nathaniel Nicandro
91a45c3ce3
Remove :jupyter-
prefix for ioloop process plist
2018-01-17 20:15:10 -06:00
Nathaniel Nicandro
bd1d4c8908
Fix callbacks when multiple callbacks exist for a single message type
2018-01-17 20:11:43 -06:00
Nathaniel Nicandro
3c1416a3f6
Add -buffer
slot for a jupyter-kernel-client
...
Since client local variables are associated with a buffer a buffer needs to be
present when the client is first initialized. This buffer is also used as the
process buffer of the ioloop subprocess.
2018-01-16 12:08:33 -06:00
Nathaniel Nicandro
e9bd7e5542
Warn if the channel subprocess did not shutdown in time
2018-01-16 12:02:23 -06:00
Nathaniel Nicandro
123a51b648
Process the list of channels once in jupyter--ioloop-filter
2018-01-16 12:01:07 -06:00
Nathaniel Nicandro
06acb2ab8c
Handle quit
signal when sending input to a kernel
2018-01-16 11:58:55 -06:00
Nathaniel Nicandro
ce19029838
Revert back to old behavior in jupyter--ioloop-filter
...
Do not rely on message handling to be fast when processing subprocess output
2018-01-16 11:55:53 -06:00
Nathaniel Nicandro
a0effbf359
Use client local value of jupyter-include-other-output
2018-01-16 11:54:11 -06:00
Nathaniel Nicandro
b50522102f
Use quoted lists
2018-01-16 11:53:35 -06:00
Nathaniel Nicandro
bb7cd76380
Handle signal interruptions when polling in the ioloop subprocess
2018-01-15 13:01:24 -06:00
Nathaniel Nicandro
faf1ee35e8
Run handler in ioloop filter
...
Do this because the process buffer is current in the filter, see
`zmq-start-process`. Since we store buffer local values of variables (like
message hooks) there we
would like to have access to them in the handlers.
2018-01-14 02:17:05 -06:00
Nathaniel Nicandro
3897eff3ba
Update comment section headers
2018-01-13 22:51:27 -06:00
Nathaniel Nicandro
0ad92ce933
Fix use of jupyter-include-other-output
2018-01-13 14:05:03 -06:00
Nathaniel Nicandro
2d83b757a6
Fix problems with with-jupyter-client-buffer
...
- Supply `with-current-buffer` with an actual buffer
- Actually expand the `client` argument
2018-01-13 13:34:02 -06:00
Nathaniel Nicandro
a5d188e32f
Move jupyter-wait-until-startup
to jupyter-kernel-manager.el
...
Also make `jupyter-wait-until-startup` private by renaming to
`jupyter--wait-until-startup`. Startup messages are only sent once at kernel
startup, since the only way to start a kernel is through a
`jupyter-kernel-manager` it makes more sense to only allow a kernel manager to
wait for a startup message.
2018-01-12 18:14:04 -06:00
Nathaniel Nicandro
7d516f2126
No need for apply-partially
2018-01-12 18:07:39 -06:00