Commit graph

2570 commits

Author SHA1 Message Date
Benda Xu
ab3cea045f lisp/ein-jupyter.el: pull more frequent for server start output. 2017-10-21 22:37:59 +09:00
Benda Xu
56d3a0157f Donot block for process. from the accept-process-output document:
Optional argument PROCESS means do not return until output has been
  received from PROCESS.

If jupyter notebook is fast enough and made all the outputs, at the
time of invoking accept-process-output will block until timeout.

Revert "ein-jupyter: Try waiting for process output before logging in."

This reverts commit 9cae1ba153.
2017-10-21 22:31:19 +09:00
Benda Xu
5ec09896a0 tools/testein.py: no retry is needed.
Our test is reproducible now.
2017-10-21 22:28:17 +09:00
Benda Xu
6a9df3680c lisp/ein-notebooklist.el: add missing '.'. 2017-10-21 22:28:17 +09:00
Benda Xu
adce9b3b24 execute and debug notebooklist-open early. 2017-10-21 22:28:17 +09:00
Benda Xu
aa907826c0 tests/func-test.el: tests should be executed in a specific order.
ERT by default uses the lexical order.
2017-10-21 22:28:03 +09:00
Benda Xu
4795debbc8 tests/func-test.el: no need to kill notebook list buffer.
It is reliable now.
2017-10-21 22:27:04 +09:00
Benda Xu
c759c9a280 lisp/ein-notebooklist.el: print password explicit in debugging mode. 2017-10-21 22:21:05 +09:00
Benda Xu
21ba5f45ac tests/func-test.el: look for URL and output captured token.
Some environment can be slow so that even if "The Jupyter Notebook is
  running" appears, the notebook URL with token is not available.

  Test exactly for the URL.
2017-10-21 22:19:38 +09:00
Benda Xu
be5000b84e .travis.yml: set up build environment.
1. no need to install git explicitly.
  2. install emacs before `cask install`, otherwise the cask packages
     are installed for system emacs.
  3. pip installation as root, otherwise the debug session
     travis_run_install hangs with 'Permission Denied'.
2017-10-21 22:19:38 +09:00
John Miller
4909b176dc Merge pull request #245 from sam-s/master
fix a typo in 34902e1
2017-10-20 13:57:29 -05:00
Sam Steingold
05ba2e257a fix a typo in 34902e1 2017-10-20 14:32:53 -04:00
John Miller
d7e1aece02 ein-company: Make sure matches actually start with right text.
This should address the original problem described in #225.
2017-10-20 12:05:01 -05:00
John Miller
34902e104f ein-company: Avoid completing around punctuation.
For some reason this causes the IPython kernel to return a very large number of
potential matches.
2017-10-20 11:55:31 -05:00
John Miller
75c3925f58 Merge pull request #242 from sam-s/master
add ein:notebook-reconnect-kernel to menu
2017-10-19 21:27:13 -05:00
Sam Steingold
0be2524001 add ein:notebook-reconnect-kernel to menu 2017-10-19 12:37:22 -04:00
John Miller
e0e3fac0c4 ein-connect: Missed a couple oref's. 2017-10-03 10:17:47 -05:00
John Miller
c0eabfe2ad ein-notebooklist: Fix possible bug specifying notebook urls
Don't think we were handling https:// url's correctly.

Also some code cleanup in ein-connect; fix longstanding bug in ein:load-files,
and tweak default timeout for starting a jupyter session from within emacs.
2017-10-03 10:04:41 -05:00
John Miller
9cae1ba153 ein-jupyter: Try waiting for process output before logging in.
Wait using `accept-process-output` before trying to look for auth tokens and
logging into the jupyter server.
2017-10-02 10:16:50 -05:00
John Miller
0b79ac056b Merge branch 'test' of git://github.com/heroxbd/emacs-ipython-notebook into heroxdb-test 2017-09-30 16:14:34 -05:00
John Miller
0bc7ab813a ein-inspector: Getting organized, remove cruft. 2017-09-30 16:06:36 -05:00
Benda Xu
77fa27cc08 tests/func-test.el: path nil is not equivalent to "".
revert to the original design.
2017-09-30 21:42:26 +09:00
Benda Xu
7c05039752 tests/func-test.el: close jupyter server after tests. 2017-09-30 21:41:15 +09:00
Benda Xu
745673926a lisp/ein-notebooklist.el: defer notebooklist instead of buffer.
The buffer could be killed after the callback.
2017-09-30 21:34:00 +09:00
Benda Xu
661bb1c7f1 .travis.yml: pass full path of jupyter to tests.
(file-exists-p server-cmd-path) in ein:jupyter-server-start
  requires full path.
2017-09-30 21:27:16 +09:00
Benda Xu
5e1f3ed665 tests/func-test.el: jupyter notebook could be started without token.
Wait for the message indicating the server has been started.
2017-09-30 21:19:16 +09:00
Benda Xu
52403097f0 tests/func-test.el: wait for the notebooklist buffer to appear. 2017-09-30 21:18:38 +09:00
Benda Xu
822ba97023 tests/func-test.el: pass kernelspec as a real ein:$kernelspec.
A simple pair does not work.
2017-09-30 21:17:09 +09:00
Benda Xu
afedb014ca tests/func-test.el: revert back to tkf's code.
cl-find does not work here.
2017-09-30 21:15:46 +09:00
Benda Xu
077de69d94 lisp/ein-notebooklist.el: dash is needed to provide -group-by. 2017-09-30 14:35:36 +09:00
Benda Xu
6683dfd252 tests/ein-testing.el: no-op when no *ein:log-all* buffer is found. 2017-09-29 18:24:20 +09:00
Benda Xu
024f353906 tests/test-ein-modes.el: mumamo has been deprecated with nXhtml.
mumamo has already been removed in 3d50f72e0a.
2017-09-29 18:22:02 +09:00
Benda Xu
3d2e41fda5 test-batch-log.log: should not have been committed. 2017-09-29 18:19:14 +09:00
John Miller
1ab98b0c9d ein-jupyter: More stable ein:jupyter-server-start
Trying to increase reliability of starting a juptyer server from Emacs. Deferred
is cool, but a pain to understand for this old brain.

Fix some typos in ein-ob and be smarter selecting completion backend when
connecting a python buffer to a jupyter notebook.
2017-09-22 14:31:14 -05:00
John Miller
3fc8d55722 ob-ein: Connect edit buffer to running notebook.
Instead of just enabling auto complete why not just connect to the notebook ala
`ein:connect-to-notebook`?

Update dependencies documented in README.rst

Force version check when starting the jupyter server - ein seems to be easily
confused in this regard.
2017-09-20 14:40:27 -05:00
John Miller
40faf6fa4d ob-ein: More robust editing setup.
Try to do the right thing if a notebook server is not running.
2017-09-19 13:49:31 -05:00
John Miller
1bcc3b87c5 ob-ein: Tap into ein autocompletion for org source edit buffers.
Will try to use ein completion backend configured by user when editing ein
source blocks in org.

Also slightly more robust inspecting in ein_inspector.py
2017-09-19 13:08:13 -05:00
John Miller
15ad1c49c7 ein-notebooklist: Order notebook list by file type.
Order entries in notebooklist by file type (i.e. file extension). Add function
'ein:jupyter-server-stop to 'kill-emacs-hook.

Fixed link in documentation.
2017-09-12 16:22:19 -05:00
John Miller
213cea559e ein-jupyter: Add timeout to ein:jupyter-server-start
Add configurable timeout (see `ein:jupyter-server-run-timeout`) that will
hopefully abort calls to `ein:jupyter-server-run` that hang; this is to help
with issues like those reported in #176.

Also update documentation, dependencies in preparation for 0.13.0 release.
2017-09-03 10:29:54 -05:00
John Miller
606d4b3214 Merge branch 'master' of github.com:millejoh/emacs-ipython-notebook
Also update loaddefs and add an additional option for ein's completion backend:
`ein:use-custom-backend'. When enabled EIN will not automatically use any
autocompletion mechanism, instead leaving the configuration details to the user.
2017-08-10 14:53:46 -05:00
John Miller
85968e476c ein-jedi: Truly integrate jedi into ac backend.
Until now autocompletion was using kernel complete mechanism regardless of
`ein:completion-backend' setting.
2017-08-03 08:50:07 -05:00
John Miller
f47f020336 Merge pull request #229 from sam-s/master
do not load ein-ac for those who want to use company
2017-08-03 08:29:30 -05:00
Sam Steingold
d9c9d18fd0 do not load ein-ac for those who want to use company 2017-08-02 10:15:38 -04:00
John Miller
d201dfadc4 Doc, dependency updates. Tweaks for Emacs 24 compatibility. 2017-07-30 11:37:44 -05:00
John Miller
4419818dde Merge branch 'back-to-eieio' 2017-07-29 23:08:35 -05:00
John Miller
4f5f29d351 ein-jupyterhub: Fix websocket connects.
Made sure to add the right cookies to the websocket request. Websockets
authenticate and everything is peachy now.
2017-07-25 16:57:32 -05:00
John Miller
9a1579d5f6 ein-jupyterhub: Support contents api
When running against jupyterhub master (which will someday be v0.8) can know log
in and make calls to the contents api.

Everything is working except for opening websocket connections.
2017-07-25 15:36:07 -05:00
John Miller
b68d8eff8f ein-jupyterhub: Make `ein:jupyterhub-connect' interactive
`ein:jupyterhub-connect' is now interactive and will query for url, user, and
password before trying to authenticate in Jupyterhub and start a server for the
user.
2017-07-21 17:39:01 -05:00
John Miller
1658e09749 ein-jupyterhub: authorize, start a server and try to open it.
We can do all of these through the function `ein:jupyterhub-connect'. Everything
works great until we actually try to access the running notebook server at which
point the hub redirects us to the login page. I've bumped to the mailing list,
we will see if anyone there can help.
2017-07-21 17:25:35 -05:00
John Miller
e2078e8951 ein-jupyterhub: Code to authroize a user with jupyterhub.
`ein:jupyterhub-connect' will take a url for the jupyterhub server, a user, and
a password and then get and store the authorization token for that user.

Big things on the way!
2017-07-21 12:36:07 -05:00