emacs-async
emacs-async copied to clipboard
emacs-async can not work in termux's emacs.
I have tested the following example, and can not get the desire output:
(async-start
;; What to do in the child process
(lambda ()
(message "This is a test")
(sleep-for 3)
222)
;; What to do when it finishes
(lambda (result)
(message "Async process done, result should be 222: %s" result)))
Anyone know how to debug the problem?
It works here; what do you see?
I only can see "process emacs" and no desire output
I might take a little while to appear. Is there any way to observe the processes on the system, to see if the child Emacs is being created and executed?
I can see the emacs process with the help of list-process, and it run about 5 minute, but there are no output showed in main emacs. Is any way to debug this ?
Using username "feng".
Authenticating with public key "imported-openssh-key"
Passphrase for key "imported-openssh-key":
Remove dead screens with 'screen -wipe'.
Loading newcomment...
Loading replace...
Loading emacs-lisp/tabulated-list...
Loading buff-menu...
Loading emacs-lisp/float-sup...
Loading vc/vc-hooks...
Loading vc/ediff-hook...
Loading uniquify...
Loading electric...
Loading emacs-lisp/eldoc...
Loading cus-start...
Loading tooltip...
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/leim/leim-list.el\
(source)...
Finding pointers to doc strings...
Finding pointers to doc strings...done
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/emacs-lisp/site-i\
nit.el (source)...
the emacs subprocess's bufffer content.
Interesting, it seems to be waiting for you to input a password in order to complete the startup process. I think you need to stop your subordinate Emacs from loading your site file or init.el
file, which it shouldn't be doing by default.
Using username "feng".
Authenticating with public key "imported-openssh-key"
Passphrase for key "imported-openssh-key":
Remove dead screens with 'screen -wipe'.
This is the infomation when I ssh with putty, I don't know why it will showed in emacs process's buffer. when I try it again, it show now:
Loading loadup.el (source)...
Using load-path (/data/data/com.termux/files/usr/share/emacs/25.3/lisp /data/data/com.termux/fi\
les/usr/share/emacs/25.3/lisp/emacs-lisp /data/data/com.termux/files/usr/share/emacs/25.3/lisp/\
language /data/data/com.termux/files/usr/share/emacs/25.3/lisp/international /data/data/com.ter\
mux/files/usr/share/emacs/25.3/lisp/textmodes /data/data/com.termux/files/usr/share/emacs/25.3/\
lisp/vc)
Loading emacs-lisp/byte-run...
Loading emacs-lisp/backquote...
Loading subr...
Loading version...
Loading widget...
Loading custom...
Loading emacs-lisp/map-ynp...
Loading international/mule...
Loading international/mule-conf...
Loading env...
Loading format...
Loading bindings...
Loading window...
Loading files...
Loading emacs-lisp/macroexp...
Loading cus-face...
Loading faces...
Loading button...
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/loaddefs.el (source)...
Loading emacs-lisp/nadvice...
Loading emacs-lisp/cl-preloaded...
Loading minibuffer...
Loading abbrev...
Loading simple...
Loading help...
Loading jka-cmpr-hook...
Loading epa-hook...
Loading international/mule-cmds...
Loading case-table...
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/international/charprop.el (sourc
...
Loading textmodes/fill...
Loading newcomment...
Loading replace...
Loading emacs-lisp/tabulated-list...
Loading buff-menu...
Loading emacs-lisp/float-sup...
Loading vc/vc-hooks...
Loading vc/ediff-hook...
Loading uniquify...
Loading electric...
Loading emacs-lisp/eldoc...
Loading cus-start...
Loading tooltip...
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/leim/leim-list.el (source)...
Finding pointers to doc strings...
Finding pointers to doc strings...done
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/emacs-lisp/site-init.el (source).\
..
I think you need to stop your subordinate Emacs from loading your site file or init.el file
This is the default behavior of termux's emacs. may be it's a bug? by the way, when I remove this file. aync can not work well still.
I don't know why it's trying to use ssh during an Emacs startup. What is the value of async-quiet-switch
on your system?
I don't know why it's trying to use ssh during an Emacs startup.
Sorry, it's just my paste problem, emacs subprocess buffer's content is normal, just like:
Loading loadup.el (source)...
Using load-path (/data/data/com.termux/files/usr/share/emacs/25.3/lisp /data/data/com.termux/fi\
les/usr/share/emacs/25.3/lisp/emacs-lisp /data/data/com.termux/files/usr/share/emacs/25.3/lisp/\
language /data/data/com.termux/files/usr/share/emacs/25.3/lisp/international /data/data/com.ter\
mux/files/usr/share/emacs/25.3/lisp/textmodes /data/data/com.termux/files/usr/share/emacs/25.3/\
lisp/vc)
Loading emacs-lisp/byte-run...
...
Loading tooltip...
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/leim/leim-list.el (source)...
Finding pointers to doc strings...
Finding pointers to doc strings...done
Loading /data/data/com.termux/files/usr/share/emacs/25.3/lisp/emacs-lisp/site-init.el (source).\
What is the value of async-quiet-switch on your system?
"-Q"
when i change to use
"--eval" "'(async-batch-invoke)'"
it can work, what the two approach different?
t> when i change to use t> "--eval" "'(async-batch-invoke)'"
What exactly did you change?
What exactly did you change?
Sorry, I have tested again, but it can not fix the problem, it just show: "Async process done, result should be 222:(sourse)", which indicated that the value is not fetched properly.