emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Terminal locked when spawning a new tty frame


From: Alex Bennée
Subject: Re: Terminal locked when spawning a new tty frame
Date: Wed, 06 Nov 2019 17:17:22 +0000
User-agent: mu4e 1.3.5; emacs 27.0.50

Alex Bennée <address@hidden> writes:

> Andreas Schwab <address@hidden> writes:
>
>> On Okt 23 2019, Alex Bennée wrote:
>>
>>> #13 0x000055ed55d1f5f6 in recursive_edit_1 () at keyboard.c:714
>>> #14 0x000055ed55d1f915 in Frecursive_edit () at keyboard.c:786
>>> #15 0x000055ed55d8e2a3 in Ffuncall (nargs=1, 
>>> args=args@entry=0x7ffd0aca1ca8) at lisp.h:2109
>>> #16 0x000055ed55dc1d51 in exec_byte_code (bytestr=<optimized out>, 
>>> vector=<optimized out>, maxdepth=<optimized out>, args_template=<optimized 
>>> out>, nargs=<optimized out>, args=<optimized out>) at bytecode.c:633
>>> #17 0x000055ed55d8e1ff in Ffuncall (nargs=3, args=0x7ffd0aca2060) at 
>>> eval.c:2808
>>> #18 0x000055ed55d8e532 in Fapply (nargs=nargs@entry=2, 
>>> args=args@entry=0x7ffd0aca20f0) at eval.c:2424
>>> #19 0x000055ed55d8e66c in apply1 (fn=<optimized out>, 
>>> arg=arg@entry=0x55ed5d981de3) at lisp.h:1399
>>> #20 0x000055ed55d8e858 in call_debugger (arg=0x55ed5d981de3) at eval.c:339
>>> #21 0x000055ed55d8ef01 in maybe_call_debugger (data=0x55ed5d1a9ec3, 
>>> sig=0xe520, conditions=0x7f26ae4ed72b) at lisp.h:1032
>>> #22 0x000055ed55d8ef01 in signal_or_quit (error_symbol=0xe520, 
>>> data=0x55ed5d1a9ec3, keyboard_quit=<optimized out>) at eval.c:1666
>>> #23 0x000055ed55c44214 in Fsignal (error_symbol=<optimized out>, 
>>> error_symbol@entry=0xe520, data=<optimized out>) at eval.c:1568
>>
>> So you have a frame inside the debugger, probably because debug-on-error
>> is non-nil.
>
> I'll check next time. I might of knocked it on by mistake. The other
> Andrés mentioned one workaround was killing an errant *Backtrace* but I
> must admit I didn't check if the debugger was active during the
> failure.

So I have a reproducer and sure enough the *Backtrace* buffer was at:

Debugger entered--Lisp error: (quit)
  irony-iotask-run(#<process Irony> #s(irony-iotask-packaged-task :task (:start 
(lambda (process buffer) (if (assq buffer (process-get process 
:unsaved-buffers)) (irony--server-send-command "reset-unsaved" 
(irony--get-buffer-path-for-server buffer)) (irony-iotask-set-result t))) 
:update irony--server-command-update :finish (lambda (process buffer) 
(process-put process :unsaved-buffers (assq-delete-all buffer (process-get 
process :unsaved-buffers))))) :args (#<process Irony> #<buffer helper.c>) 
:result #s(irony-iotask-result :-tag nil :-value nil :-error nil :-error-data 
nil) :plist nil :continuation #s(irony-iotask-packaged-task :task (:start 
(lambda (process buffer buf-state) (let ((elem ...) temp-file) (if (eq ... 
buf-state) (irony-iotask-set-result t) (setq temp-file ...) (irony-iotask-put 
:temp-file temp-file) (irony-iotask-put :buffer-state buf-state) (process-put 
process :buffer-state buf-state) (with-current-buffer buffer ... ...)))) 
:update irony--server-command-update :finish (lambda (&rest _args) (delete-file 
(irony-iotask-get :temp-file))) :on-success (lambda (process buffer &rest 
_args) (let* ((unsaved-buffers ...) (elem ...) (buf-state ...)) (if elem 
(setcdr elem buf-state) (process-put process :unsaved-buffers ...))))) :args 
(#<process Irony> #<buffer gdbstub.c<arm>> #s(irony--buffer-state :file 
"/home/alex/lsrc/qemu.git/target/arm/gdbstub.c" :exists t :modified t :tick 
3269)) :result #s(irony-iotask-result :-tag nil :-value nil :-error nil 
:-error-data nil) :plist nil :continuation #s(irony-iotask-packaged-task :task 
(:start (lambda (file line column compile-options) (apply 
#'irony--server-send-command "complete" file line column "--" compile-options)) 
:update irony--server-command-update) :args 
("/home/alex/lsrc/qemu.git/target/arm/gdbstub.c" 173 10 ("-x" "c")) :result 
#s(irony-iotask-result :-tag nil :-value nil :-error nil :-error-data nil) 
:plist nil :continuation #s(irony-iotask-packaged-task :task (:start (lambda 
(prefix style) (irony--server-send-command "candidates" prefix ...)) :update 
irony--server-query-update) :args ("dyn_svereg_xml" exact) :result 
#s(irony-iotask-result :-tag nil :-value nil :-error nil :-error-data nil) 
:plist nil :continuation nil)))))
  irony--run-task(#s(irony-iotask-packaged-task :task (:start (lambda (process 
buffer) (if (assq buffer (process-get process :unsaved-buffers)) 
(irony--server-send-command "reset-unsaved" (irony--get-buffer-path-for-server 
buffer)) (irony-iotask-set-result t))) :update irony--server-command-update 
:finish (lambda (process buffer) (process-put process :unsaved-buffers 
(assq-delete-all buffer (process-get process :unsaved-buffers))))) :args 
(#<process Irony> #<buffer helper.c>) :result #s(irony-iotask-result :-tag nil 
:-value nil :-error nil :-error-data nil) :plist nil :continuation 
#s(irony-iotask-packaged-task :task (:start (lambda (process buffer buf-state) 
(let ((elem ...) temp-file) (if (eq ... buf-state) (irony-iotask-set-result t) 
(setq temp-file ...) (irony-iotask-put :temp-file temp-file) (irony-iotask-put 
:buffer-state buf-state) (process-put process :buffer-state buf-state) 
(with-current-buffer buffer ... ...)))) :update irony--server-command-update 
:finish (lambda (&rest _args) (delete-file (irony-iotask-get :temp-file))) 
:on-success (lambda (process buffer &rest _args) (let* ((unsaved-buffers ...) 
(elem ...) (buf-state ...)) (if elem (setcdr elem buf-state) (process-put 
process :unsaved-buffers ...))))) :args (#<process Irony> #<buffer 
gdbstub.c<arm>> #s(irony--buffer-state :file 
"/home/alex/lsrc/qemu.git/target/arm/gdbstub.c" :exists t :modified t :tick 
3269)) :result #s(irony-iotask-result :-tag nil :-value nil :-error nil 
:-error-data nil) :plist nil :continuation #s(irony-iotask-packaged-task :task 
(:start (lambda (file line column compile-options) (apply 
#'irony--server-send-command "complete" file line column "--" compile-options)) 
:update irony--server-command-update) :args 
("/home/alex/lsrc/qemu.git/target/arm/gdbstub.c" 173 10 ("-x" "c")) :result 
#s(irony-iotask-result :-tag nil :-value nil :-error nil :-error-data nil) 
:plist nil :continuation #s(irony-iotask-packaged-task :task (:start (lambda 
(prefix style) (irony--server-send-command "candidates" prefix ...)) :update 
irony--server-query-update) :args ("dyn_svereg_xml" exact) :result 
#s(irony-iotask-result :-tag nil :-value nil :-error nil :-error-data nil) 
:plist nil :continuation nil)))))
  irony-completion-at-point()
  completion--capf-wrapper(irony-completion-at-point optimist)
  run-hook-wrapped(completion--capf-wrapper irony-completion-at-point optimist)
  company--capf-data-real()
  company--capf-data()
  company-capf(prefix)
  apply(company-capf prefix)
  company-call-backend-raw(prefix)
  apply(company-call-backend-raw prefix)
  company--force-sync(company-call-backend-raw (prefix) company-capf)
  company-call-backend(prefix)
  company--begin-new()
  company--perform()
  company-auto-begin()
  company-idle-begin(#<buffer gdbstub.c<arm>> #<window 806 on gdbstub.c<arm>> 
3269 5417)
  apply(company-idle-begin (#<buffer gdbstub.c<arm>> #<window 806 on 
gdbstub.c<arm>> 3269 5417))
  timer-event-handler([t 24001 55199 331097 nil company-idle-begin (#<buffer 
gdbstub.c<arm>> #<window 806 on gdbstub.c<arm>> 3269 5417) nil 869000])
  read-event(nil t 3)
  sit-for(3)
  flyspell-check-word-p()
  flyspell-post-command-hook()

Killing the *Backtrace* buffer restores things to working. It doesn't
seem to be specific to the backtrace as I can C-g while switching
buffers and get:

Debugger entered--Lisp error: (quit)
  read-from-minibuffer("Switch to buffer: " nil (keymap (keymap (11 . 
ivy-switch-buffer-kill)) keymap (36 . ivy-magic-read-file-env) (3 keymap (19 . 
ivy-rotate-sort) (1 . ivy-toggle-ignore) (15 . ivy-occur)) (67108903 . ivy-avy) 
(33554464 . ivy-restrict-to-matches) (15 . hydra-ivy/body) (22 . 
ivy-scroll-up-command) (prior . ivy-scroll-down-command) (next . 
ivy-scroll-up-command) (7 . minibuffer-keyboard-quit) (right . 
ivy-forward-char) (32 . self-insert-command) (18 . ivy-reverse-i-search) (19 . 
ivy-next-line-or-history) (remap keymap (describe-mode . ivy-help) 
(kill-ring-save . ivy-kill-ring-save) (kill-whole-line . ivy-kill-whole-line) 
(kill-line . ivy-kill-line) (scroll-down-command . ivy-scroll-down-command) 
(scroll-up-command . ivy-scroll-up-command) (end-of-buffer . ivy-end-of-buffer) 
(beginning-of-buffer . ivy-beginning-of-buffer) (kill-word . ivy-kill-word) 
(forward-char . ivy-forward-char) (delete-char . ivy-delete-char) 
(backward-kill-word . ivy-backward-kill-word) (backward-delete-char-untabify . 
ivy-backward-delete-char) (delete-backward-char . ivy-backward-delete-char) 
(previous-line . ivy-previous-line) (next-line . ivy-next-line)) (9 . 
ivy-partial-or-done) (10 . ivy-alt-done) (27 keymap (1 . ivy-read-action) (15 . 
ivy-dispatching-call) (111 . ivy-dispatching-done) (25 . 
ivy-insert-current-full) (105 . ivy-insert-current) (106 . ivy-yank-word) (114 
. ivy-toggle-regexp-quote) (16 . ivy-previous-line-and-call) (14 . 
ivy-next-line-and-call) (118 . ivy-scroll-down-command) (112 . 
ivy-previous-history-element) (110 . ivy-next-history-element) (10 . 
ivy-immediate-done) (13 . ivy-call)) (mouse-3 . ivy-mouse-dispatching-done) 
(mouse-1 . ivy-mouse-done) (down-mouse-1 . ignore) (13 . ivy-done)) nil 
ivy-history)
  ivy-read("Switch to buffer: " internal-complete-buffer :keymap (keymap (11 . 
ivy-switch-buffer-kill)) :preselect "*Backtrace*" :action 
ivy--switch-buffer-action :matcher ivy--switch-buffer-matcher :caller 
ivy-switch-buffer)
  ivy-switch-buffer()
  funcall-interactively(ivy-switch-buffer)
  call-interactively(ivy-switch-buffer nil nil)
  command-execute(ivy-switch-buffer)

And the same hang will be observed - although in the above case if you
complete the buffer selection the hang goes away and the new terminal
window is usable.

>
>>
>> Andreas.


--
Alex Bennée



reply via email to

[Prev in Thread] Current Thread [Next in Thread]