Nathaniel Nicandro
1658cd0454
jupyter-kill-kernel (jupyter-server-kernel): Do nothing
...
There is no need to forcibly kill a kernel since the notebook handles this
already.
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
5bd164c224
Error when trying to read a notebook through a server
...
We can't do much with a JSON representation of a notebook right now.
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
9241296b45
jupyter-api-request: Ask for authorization on next request after an un-authorized one
...
What is a better solution?
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
194df39643
Separate tests that use a notebook server from the main tests
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
de320f83d2
jupyter-current-server: Also consider a remote default-directory
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
4a87d35f76
Jupyter notebook contents API integration with TRAMP
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
e8edd4d5cc
Promote time encoding/decoding functions to public
...
Also use `parse-iso8601-time-string` when decoding
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
1d282c948a
Support kernel servers via org-mode
source blocks
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
67831c08fa
Support Jupyter kernel servers
...
* jupyter-client.el (jupyter-initialize-connection): Elevate NOTE to FIXME.
(jupyter-kernel-info): Extend timeout.
* jupyter-kernel-manager.el (jupyter-shutdown-kernel):
(jupyter-interrupt-kernel): Allow any number of arguments.
* jupyter-kernelspec.el (jupyter-find-kernelspecs): Optionally allow specs.
* jupyter-messages.el (jupyter-encode-raw-message): New function.
* jupyter-rest-api.el (jupyter-api-auth-headers): New function.
* jupyter-server-ioloop.el: New file.
* jupyter-server.el: New file.
* test/jupyter-test.el (jupyter-server):
(jupyter-server-kernel-manager):
(jupyter-server-start-new-kernel): New tests.
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
9df340bd0f
Add REST API
...
* jupyter-rest-api.el: New file.
* test/jupyter-test.el (jupyter-rest-api):
(jupyter-api--copy-cookies, jupyter-api--password-login):
(jupyter-api-kernel-ws): New tests.
* test/test-helper.el (jupyter-test-rest-api): New macro.
2019-07-24 16:59:04 -05:00
Nathaniel Nicandro
6650dd3588
Bump version
2019-07-24 16:03:22 -05:00
Nathaniel Nicandro
27f7c25bfa
Update CHANGELOG
2019-07-24 16:03:22 -05:00
Nathaniel Nicandro
e0531d040c
jupyter-repl-ret: Suppress all handlers except :is-complete-reply
...
Fixes #153 .
2019-07-24 14:59:47 -05:00
Nathaniel Nicandro
1e10e161b7
jupyter-ioloop-timeout: Add documentation
2019-07-24 14:40:55 -05:00
Nathaniel Nicandro
1e6e83c12e
Preserve outline visibility
...
* jupyter-org-extensions.el (jupyter-org-closest-jupyter-language)
(jupyter-org-between-block-end-and-result-p):
(jupyter-org-next-busy-src-block):
(jupyter-org-move-src-block): Do it.
2019-07-24 14:40:55 -05:00
Ruslan
7918293c41
Added warning to README.org about possible conflicts with ob-ipython ( #135 )
2019-07-24 12:50:41 -05:00
Nathaniel Nicandro
6b86fedb10
org-babel-jupyter-make-language-alias: Make sure variable is bound
2019-07-18 17:21:53 -05:00
Nathaniel Nicandro
cd127c5cb4
Silence byte compiler warning
2019-07-18 17:08:53 -05:00
Nathaniel Nicandro
f8796aa13f
Partially revert "0f01a2a2ed36ffc676d1d5f39e2c3f562ad2ca03"
...
The normal way of loading `ob-jupyter` is through `org-babel-do-load-languages`
so a users `exec-path` should be enabled by that time and so there is a higher
chance that it is setup correctly. See #151 .
2019-07-18 15:38:23 -05:00
Nathaniel Nicandro
857f5e5071
org-babel-jupyter-make-language-alias: Don't overwrite variables that already exist
...
Also, set the :kernel header argument in the default header arguments for a
language if not already present.
2019-07-18 15:35:15 -05:00
Nathaniel Nicandro
f906e62ed0
Simplify wording in README
2019-07-17 15:53:14 -05:00
Nathaniel Nicandro
cb1efa4268
jupyter-org--image-result: Fix a few issues
...
* jupyter-org-client.el (jupyter-org--image-result):
Be more stringent on checking the value of `org-image-actual-width`. `listp`
returns t when passed nil, a valid value of `org-image-actual-width`.
Use absolute filenames when calling `create-image`.
2019-07-14 17:56:33 -05:00
Nathaniel Nicandro
2992e24e57
jupyter-org--image-result: Fix byte-compile warning, update documentation
...
* jupyter-org-client.el (jupyter-org-adjust-image-size): Cleanup documentation.
(jupyter-org--image-result): Do it.
2019-07-14 17:20:41 -05:00
Nathaniel Nicandro
bf5589e428
Avoid use of jupyter-ioloop-wait-until
...
* jupyter-channel-ioloop-comm.el (jupyter-stop-channel)
(jupyter-start-channel): Do it.
See https://github.com/dzop/emacs-jupyter/issues/148#issuecomment-511219046
In reality `jupyter-ioloop-wait-until` should be fixed to handle the case of
multiple events coming in before checking the waiting condition, but in this
case we can just check the liveness of the channels.
2019-07-14 17:20:41 -05:00
Nathaniel Nicandro
abc029fd41
jupyter-get: Return nil on unbound variables, make setf
-able
...
* jupyter-client.el (jupyter-get): Do it.
2019-07-14 17:20:41 -05:00
Nathaniel Nicandro
653f934bfc
Add jupyter-org-(next|previous)-busy-src-block
...
* jupyter-org-extensions.el (jupyter-org-next-busy-src-block)
(jupyter-org-previous-busy-src-block): Do it.
(jupyter-org-hydra/body): Add N and P bindings.
2019-07-14 17:20:41 -05:00
Nathaniel Nicandro
1b1a55ef3f
Add jupyter-org-request-at-point
...
* jupyter-org-client.el (jupyter-org-request-at-point): Do it.
(org-babel-jupyter-src-block-session): New declare.
* ob-jupyter.el (org-babel-jupyter-session-clients): Add doc about keys.
* test/jupyter-test.el (jupyter-org-request-at-point): New test.
2019-07-14 17:20:41 -05:00
Nathaniel Nicandro
259e8c5b86
Add jupyter-map-pending-requests
...
* jupyter-client.el (jupyter-map-pending-requests): Do it.
* test/jupyter-test.el (jupyter-map-pending-requests): New test.
2019-07-14 17:20:41 -05:00
Nathaniel Nicandro
1e9da5753d
Add jupyter-org-interrupt-kernel
...
* jupyter-org-extensions.el (jupyter-org-interrupt-kernel): Do it.
(jupyter-org-hydra/body): Add i binding.
* jupyter-repl.el (jupyter-repl-interrupt-kernel): Clarify error message.
2019-07-14 17:20:18 -05:00
Nathaniel Nicandro
df6651a1f1
jupyter-org-result: More informative error
...
* jupyter-org-client.el (jupyter-org-result): Do it.
2019-07-14 17:03:38 -05:00
Yevgnen
c5c2c84a0d
Add jupyter-org-adjust-image-size
( #147 )
2019-07-14 12:44:31 -05:00
Nathaniel Nicandro
7c1689e33d
jupyter-org-client.el: Don't assume non-empty strings
2019-07-11 16:40:37 -05:00
Nathaniel Nicandro
e084842242
jupyter-org-insert-src-block: Don't move past an inlinetask
2019-07-10 19:24:06 -05:00
Nathaniel Nicandro
642b0ef592
jupyter-org-insert-src-block: Be aware of a src-block's results
...
When `point` is between a src-block and its result with only whitespace
separating the end of a src-block and the beginning of its results, insert a
new src-block after the result.
2019-07-10 17:28:58 -05:00
Nathaniel Nicandro
08a4723c0b
jupyter-widgets-on-message: Fix wrong argument to jupyter-send
2019-07-10 12:02:13 -05:00
Nathaniel Nicandro
d5492c54fb
jupyter-runtime-directory: Use an existing directory
...
Set `default-directory` to one that should exist otherwise tests fail on
Appveyor.
2019-07-09 13:50:27 -05:00
Nathaniel Nicandro
31b551bdc1
org-babel-jupyter--run-repl: Make language aliases for remote kernelspecs
2019-07-09 13:50:20 -05:00
Nathaniel Nicandro
0f01a2a2ed
ob-jupyter.el: Don't make language aliases at load time
2019-07-09 13:47:17 -05:00
Nathaniel Nicandro
fb0317acdd
Raise errors when jupyter-command
returns nil
...
* jupyter-env.el (jupyter-runtime-directory): Do it.
* jupyter-kernelspec.el (jupyter-available-kernelspecs): Do it.
2019-07-09 13:47:17 -05:00
Nathaniel Nicandro
7b78ca7013
jupyter-runtime-directory: Don't call shell commands at load time
...
* jupyter-env.el (jupyter-runtime-directory): Remove custom status.
New function definition.
* jupyter-kernel-manager.el (jupyter-write-connection-file):
Use new function.
* ob-jupyter.el (org-babel-jupyter--run-repl):
Remove setting of `jupyter-runtime-directory`.
* test/jupyter-test.el (jupyter-runtime-directory): New test.
2019-07-08 20:23:23 -05:00
Nathaniel Nicandro
4f944d311c
jupyter-send (jupyter-ioloop): Fix placement of setq
2019-07-08 17:27:29 -05:00
Nathaniel Nicandro
4daa09bb15
jupyter-send (jupyter-ioloop): Don't create a temporary buffer on every send
2019-07-08 16:56:36 -05:00
Nathaniel Nicandro
02a0b470d9
jupyter-ioloop: Fix for subprocess stdin buffering issue
2019-07-08 16:56:28 -05:00
Nathaniel Nicandro
909cdf3dd7
jupyter-org-insert-src-block: Add blank lines where appropriate
2019-07-01 11:49:17 -05:00
Nathaniel Nicandro
23a692d0b4
jupyter-completion-prefix (julia): Don't keep :
prefix on non-symbol looking prefixes
2019-07-01 11:49:17 -05:00
Nathaniel Nicandro
6f0686e186
jupyter-kernel-info: Increase timeout again
...
Needed much more often for the IJulia kernel when starting it via the notebook
support landing soon.
2019-07-01 11:46:57 -05:00
Nathaniel Nicandro
f5d852dc6d
Fix macro hygiene issues
2019-06-30 12:36:41 -05:00
Nathaniel Nicandro
4c3168d53f
Add jupyter-server-mode-set-client
...
This is an attempt at associating a REPL client with a buffer which was created
by emacsclient.
2019-06-30 12:36:41 -05:00
Nathaniel Nicandro
8f9ec15af0
Add jupyter-org-table-string
2019-06-30 12:22:26 -05:00
Nathaniel Nicandro
aedd0d41d6
Update README
2019-06-30 12:22:26 -05:00