all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: [Emacs-diffs] /srv/bzr/emacs/trunk r108646: * minibuffer.el (read-file-name-default): Bind `non-essential' to `t'.
Date: Mon, 18 Jun 2012 11:00:34 +0200	[thread overview]
Message-ID: <87k3z5ouz1.fsf@gmx.de> (raw)
In-Reply-To: jwvy5nl1i4v.fsf-monnier+emacs@gnu.org

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>>   * minibuffer.el (read-file-name-default): Bind `non-essential' to `t'.
>
> This is wrong.  At the time it happens, it is the main focus of the
> user's interaction, so it is very much essential.

`non-essential' is meant to protect user interaction from undesired
events like connection establishing, including password request
etc. Usually, it is the task of the several file name completion
packages to care. Ido and icomplete, for example, behave like this.

However, without the patch in minibuffer, it still happens. This is due
to a `file-exists-p' call somewhere in the completion.

Maybe there is a better place to bind `non-essential'. But I still don't
understand all the completion code :-(

Here's a recipe to reproduce the problem (revert the patch in
minibuffer.el first):

emacs -Q -l icomplete -f icomplete-mode
C-x C-f /ssh:localhost:/ <TAB>

When quitting the password request, there's the backtrace

Debugger entered--Lisp error: (quit)
  signal(quit nil)
  byte-code("\302^H!\210\303    @       A\"\207" [vec err tramp-cleanup signal] 3)
  byte-code("\306^H!\307^H\310\311#\312 !r\313^H!q\210`)^Z^Y^[\211^\\203)^@\314\f!\203)^@\315\f!\316>\204E^@\317\320^H\311\"!^M@\232\203E^@\321\322 ^MA\"\32$
  tramp-maybe-open-connection(["ssh" nil "localhost" "/" nil])
  tramp-send-command(["ssh" nil "localhost" "/" nil] "echo \\\"`getconf PATH 2>/dev/null`\\\" 2>/dev/null; echo tramp_exit_status $?")
  tramp-send-command-and-check(["ssh" nil "localhost" "/" nil] "echo \\\"`getconf PATH 2>/dev/null`\\\"")
  tramp-send-command-and-read(["ssh" nil "localhost" "/" nil] "echo \\\"`getconf PATH 2>/dev/null`\\\"" noerror)
  tramp-get-remote-path(["ssh" nil "localhost" "/" nil])
  tramp-get-remote-perl(["ssh" nil "localhost" "/" nil])
  tramp-sh-handle-file-name-all-completions("" "/ssh:localhost:/")
  apply(tramp-sh-handle-file-name-all-completions ("" "/ssh:localhost:/"))
  tramp-sh-file-name-handler(file-name-all-completions "" "/ssh:localhost:/")
  apply(tramp-sh-file-name-handler file-name-all-completions ("" "/ssh:localhost:/"))
  byte-code("\300\301\215\207" [suppress (apply foreign operation args)] 2)
  #[nil "^HK\306^Y\211^Z<\203\240^@\n@\307=\203\240^@\306^[\310\311!\203\"^@\312\311\313N@!\202\221^@\314\315!\2039^@\316\315!\2044^@\317\315!\205\221^@\315$
  funcall(#[nil "^HK\306^Y\211^Z<\203\240^@\n@\307=\203\240^@\306^[\310\311!\203\"^@\312\311\313N@!\202\221^@\314\315!\2039^@\316\315!\2044^@\317\315!\205\2$
  tramp-file-name-handler(file-name-all-completions "" "/ssh:localhost:/")
  file-name-all-completions("" "/ssh:localhost:/")
  tramp-handle-file-name-completion("" "/ssh:localhost:/" file-exists-p)
  apply(tramp-handle-file-name-completion ("" "/ssh:localhost:/" file-exists-p))
  tramp-sh-file-name-handler(file-name-completion "" "/ssh:localhost:/" file-exists-p)
  apply(tramp-sh-file-name-handler file-name-completion ("" "/ssh:localhost:/" file-exists-p))
  byte-code("\300\301\215\207" [suppress (apply foreign operation args)] 2)
  #[nil "^HK\306^Y\211^Z<\203\240^@\n@\307=\203\240^@\306^[\310\311!\203\"^@\312\311\313N@!\202\221^@\314\315!\2039^@\316\315!\2044^@\317\315!\205\221^@\315$
  funcall(#[nil "^HK\306^Y\211^Z<\203\240^@\n@\307=\203\240^@\306^[\310\311!\203\"^@\312\311\313N@!\202\221^@\314\315!\2039^@\316\315!\2044^@\317\315!\205\2$
  tramp-file-name-handler(file-name-completion "" "/ssh:localhost:/" file-exists-p)
  file-name-completion("" "/ssh:localhost:/" file-exists-p)
  #[0 "\302\306=\203^H^@\307\207\310\300\311^[^\^]\312^^^_\313^M\f^K#,\203)^@\314\315\316\317\320 \"\300\321\311O\301\302%\207\302\242\322=\203M^@\323\300!G$
  funcall(#[0 "\302\306=\203^H^@\307\207\310\300\311^[^\^]\312^^^_\313^M\f^K#,\203)^@\314\315\316\317\320 \"\300\321\311O\301\302%\207\302\242\322=\203M^@\3$
  completion-file-name-table("/ssh:localhost:/" file-exists-p nil)
  try-completion("/ssh:localhost:/" completion-file-name-table file-exists-p)
  completion-basic-try-completion("/ssh:localhost:/" completion-file-name-table file-exists-p 16)
  #[257 "\300^A^M\2368\301@\302@\303\304@$\207" [1 ("/ssh:localhost:/") (completion-file-name-table) file-exists-p (16) completion-styles-alist] 6 "\n\n(fn $
  #[0 "\302\300\301@\301\211@A\240\210@!\240\207" [#[257 "\300^A^M\2368\301@\302@\303\304@$\207" [1 ("/ssh:localhost:/") (completion-file-name-table) file-e$
  funcall(#[0 "\302\300\301@\301\211@A\240\210@!\240\207" [#[257 "\300^A^M\2368\301@\302@\303\304@$\207" [1 ("/ssh:localhost:/") (completion-file-name-table$
  completion--some(#[257 "\300^A^M\2368\301@\302@\303\304@$\207" [1 ("/ssh:localhost:/") (completion-file-name-table) file-exists-p (16) completion-styles-a$
  completion--nth-completion(1 "/ssh:localhost:/" read-file-name-internal file-exists-p 16 (metadata (category . file) (completion--unquote-requote . t)))
  completion-try-completion("/ssh:localhost:/" read-file-name-internal file-exists-p 16 (metadata (category . file) (completion--unquote-requote . t)))
  completion--do-completion()
  minibuffer-complete()
  call-interactively(minibuffer-complete nil nil)
  read-from-minibuffer("Find file: " "~/src/emacs/" (keymap (keymap (32)) keymap (10 . minibuffer-complete-and-exit) (13 . minibuffer-complete-and-exit) key$
  completing-read-default("Find file: " read-file-name-internal file-exists-p confirm-after-completion "~/src/emacs/" file-name-history "~/src/emacs/" nil)
  completing-read("Find file: " read-file-name-internal file-exists-p confirm-after-completion "~/src/emacs/" file-name-history "~/src/emacs/")
  read-file-name-default("Find file: " nil "~/src/emacs/" confirm-after-completion nil nil)
  read-file-name("Find file: " nil "~/src/emacs/" confirm-after-completion)
  find-file-read-args("Find file: " confirm-after-completion)
  byte-code("\300\301\302 \"\207" [find-file-read-args "Find file: " confirm-nonexistent-file-or-buffer] 3)
  call-interactively(find-file nil nil)

>         Stefan

Best regards, Michael.



  reply	other threads:[~2012-06-18  9:00 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <E1SgKyP-0002jR-81@vcs.savannah.gnu.org>
2012-06-18  2:15 ` [Emacs-diffs] /srv/bzr/emacs/trunk r108646: * minibuffer.el (read-file-name-default): Bind `non-essential' to `t' Stefan Monnier
2012-06-18  9:00   ` Michael Albinus [this message]
2012-06-18 14:03     ` Stefan Monnier
2012-06-18 14:58       ` [Emacs-diffs] /srv/bzr/emacs/trunk r108646: * minibuffer.el(read-file-name-default): " Drew Adams
2012-06-18 15:59         ` Stefan Monnier
2012-06-18 19:58           ` Drew Adams
2012-06-18 21:20             ` Stefan Monnier
2012-06-19 12:36               ` Michael Albinus
2012-06-19 13:16                 ` Drew Adams
2012-06-19 13:35                   ` Michael Albinus
2012-06-19 16:29                     ` Stefan Monnier
2012-06-19 19:03                       ` Michael Albinus
2012-06-20  6:57                         ` Michael Albinus
2012-06-20 13:29                           ` Drew Adams
2012-06-18 16:47       ` [Emacs-diffs] /srv/bzr/emacs/trunk r108646: * minibuffer.el (read-file-name-default): " Michael Albinus
2012-06-18 20:35         ` Stefan Monnier
2012-06-18 20:41           ` Michael Albinus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k3z5ouz1.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.