From unknown Wed Aug 20 04:12:10 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#11714 <11714@debbugs.gnu.org> To: bug#11714 <11714@debbugs.gnu.org> Subject: Status: 24.1.50; find-file completion on a remote directory Reply-To: bug#11714 <11714@debbugs.gnu.org> Date: Wed, 20 Aug 2025 11:12:10 +0000 retitle 11714 24.1.50; find-file completion on a remote directory reassign 11714 emacs submitter 11714 Dani Moncayo severity 11714 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 15 03:55:19 2012 Received: (at submit) by debbugs.gnu.org; 15 Jun 2012 07:55:19 +0000 Received: from localhost ([127.0.0.1]:43606 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SfRNH-00041H-9J for submit@debbugs.gnu.org; Fri, 15 Jun 2012 03:55:19 -0400 Received: from eggs.gnu.org ([208.118.235.92]:58133) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SfRNE-00041A-Ov for submit@debbugs.gnu.org; Fri, 15 Jun 2012 03:55:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SfRKI-0000wR-Nu for submit@debbugs.gnu.org; Fri, 15 Jun 2012 03:52:18 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:52564) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SfRKI-0000vQ-HS for submit@debbugs.gnu.org; Fri, 15 Jun 2012 03:52:14 -0400 Received: from eggs.gnu.org ([208.118.235.92]:59957) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SfRKC-0004nY-EP for bug-gnu-emacs@gnu.org; Fri, 15 Jun 2012 03:52:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SfRK5-0000nt-RG for bug-gnu-emacs@gnu.org; Fri, 15 Jun 2012 03:52:07 -0400 Received: from mail-ob0-f169.google.com ([209.85.214.169]:33394) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SfRK5-0000iZ-K8 for bug-gnu-emacs@gnu.org; Fri, 15 Jun 2012 03:52:01 -0400 Received: by mail-ob0-f169.google.com with SMTP id ta14so3652177obb.0 for ; Fri, 15 Jun 2012 00:51:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=e7thx6e/3uwC6f6jGDy+V5kOuRRrDODo0N8UYV7/Oko=; b=GCAxXVAFis2IOa0gZD/Gj67evfiRQgYT1ZGmig26efKwBZVxayxRzkhyDdPW4CRf2x sXH1vvkRErU1UMRO9vFLqs6kvnAE+TZctOIGqPlnUmrfbPS+PLBGXq3G5BDialeTnMgl 5WKvosDCMKEsVpwufCrfLNewnm+s/JjGe54NvaEkxILyGzlI9RcNmFXINKvD8n76+az7 kR0Lwc5lRjGGu/IQD5QRPo79Db9wy5qVFbMZrR3rsm/zE66qjDzZt2FC9vOael8DLDIQ GiZMkDQKWHCz7wqdKnti7OtBf0KEiniiij40vTmtv5QdLRIzrHv7D4gUw6hSF1YHArYt aqoQ== MIME-Version: 1.0 Received: by 10.182.40.5 with SMTP id t5mr4817173obk.68.1339746719841; Fri, 15 Jun 2012 00:51:59 -0700 (PDT) Received: by 10.60.172.11 with HTTP; Fri, 15 Jun 2012 00:51:59 -0700 (PDT) Date: Fri, 15 Jun 2012 09:51:59 +0200 Message-ID: Subject: 24.1.50; find-file completion on a remote directory From: Dani Moncayo To: bug-gnu-emacs@gnu.org Content-Type: text/plain; charset=ISO-8859-1 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 208.118.235.17 X-Spam-Score: -6.1 (------) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) Recipe from "emacs -Q": 1. Eval: (cd "/some-user@some-host:~") 2. Give the correct password. 3. Type: C-x C-f / h o m e / s o m e - u s e r / t TAB After doing that, I get the error message: Assertion failed: (equal (funcall unquote qstring) completion) In the *Messages* buffer the message has more info: completion--twq-try: Assertion failed: (equal (funcall unquote qstring) completion) [I'm using the "pscp" Tramp method.] In GNU Emacs 24.1.50.1 (i386-mingw-nt6.1.7601) of 2012-06-14 on DANI-PC Bzr revision: 108603 rgm@gnu.org-20120613181105-t7txabt3lyx44f60 Windowing system distributor `Microsoft Corp.', version 6.1.7601 Configured using: `configure --with-gcc (4.7) --no-opt --enable-checking --cflags -I../../libs/giflib-4.1.4-1/include -I../../emacs/libs/gnutls-3.0.16/include -I../../libs/jpeg-6b-4/include -I../../libs/libpng-1.4.10 -I../../libs/libxpm-3.5.8/include -I../../libs/libxpm-3.5.8/src -I../../libs/tiff-3.8.2-1/include -I../../libs/zlib-1.2.6' -- Dani Moncayo From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 15 05:40:00 2012 Received: (at control) by debbugs.gnu.org; 15 Jun 2012 09:40:00 +0000 Received: from localhost ([127.0.0.1]:43689 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SfT0a-0006M6-LL for submit@debbugs.gnu.org; Fri, 15 Jun 2012 05:40:00 -0400 Received: from mailout-de.gmx.net ([213.165.64.22]:46354) by debbugs.gnu.org with smtp (Exim 4.72) (envelope-from ) id 1SfT0Z-0006Lz-Ch for control@debbugs.gnu.org; Fri, 15 Jun 2012 05:40:00 -0400 Received: (qmail invoked by alias); 15 Jun 2012 09:36:59 -0000 Received: from p57BB9751.dip0.t-ipconnect.de (EHLO detlef.gmx.de) [87.187.151.81] by mail.gmx.net (mp034) with SMTP; 15 Jun 2012 11:36:59 +0200 X-Authenticated: #3708877 X-Provags-ID: V01U2FsdGVkX19PdQ15lg9PiZY+6+xIbRHjSkTnZTn3MW8Te5eaKn gWCtcH8hVeuUuC Date: Fri, 15 Jun 2012 11:36:57 +0200 Message-Id: <87haucsypy.fsf@gmx.de> To: control@debbugs.gnu.org From: Michael Albinus Subject: control message for bug #11714 X-Y-GMX-Trusted: 0 X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) merge 11714 11628 From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 15 05:42:46 2012 Received: (at 11714) by debbugs.gnu.org; 15 Jun 2012 09:42:46 +0000 Received: from localhost ([127.0.0.1]:43694 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SfT3G-0006QJ-3l for submit@debbugs.gnu.org; Fri, 15 Jun 2012 05:42:46 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]:39995) by debbugs.gnu.org with smtp (Exim 4.72) (envelope-from ) id 1SfT3E-0006QC-QW for 11714@debbugs.gnu.org; Fri, 15 Jun 2012 05:42:45 -0400 Received: (qmail invoked by alias); 15 Jun 2012 09:39:45 -0000 Received: from p57BB9751.dip0.t-ipconnect.de (EHLO detlef.gmx.de) [87.187.151.81] by mail.gmx.net (mp069) with SMTP; 15 Jun 2012 11:39:45 +0200 X-Authenticated: #3708877 X-Provags-ID: V01U2FsdGVkX1/XNmNi9GzX2uVm9hUB5WHJpgv7cGKXP06SzPsHrf 9VAnmLIOcACkMv From: Michael Albinus To: Dani Moncayo Subject: Re: bug#11714: 24.1.50; find-file completion on a remote directory References: Date: Fri, 15 Jun 2012 11:39:42 +0200 In-Reply-To: (Dani Moncayo's message of "Fri, 15 Jun 2012 09:51:59 +0200") Message-ID: <87d350syld.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Y-GMX-Trusted: 0 X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 11714 Cc: 11714@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) Dani Moncayo writes: > Recipe from "emacs -Q": > 1. Eval: (cd "/some-user@some-host:~") > 2. Give the correct password. > 3. Type: C-x C-f / h o m e / s o m e - u s e r / t TAB > > After doing that, I get the error message: > Assertion failed: (equal (funcall unquote qstring) completion) This is the same problem as #11628. Unfortunately, I have no clue how to fix it. Stefan? Best regards, Michael. From debbugs-submit-bounces@debbugs.gnu.org Fri Jun 22 23:57:26 2012 Received: (at 11714-done) by debbugs.gnu.org; 23 Jun 2012 03:57:26 +0000 Received: from localhost ([127.0.0.1]:53351 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SiHTR-0004eS-Tv for submit@debbugs.gnu.org; Fri, 22 Jun 2012 23:57:26 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:17478) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SiHTP-0004eL-G6 for 11714-done@debbugs.gnu.org; Fri, 22 Jun 2012 23:57:23 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ai0FAG6Zu09MCrYj/2dsb2JhbAA7CbBIg0mBCIIVAQEEAScvIxALMAQIChQYDSSIHAWrEo53ixiCEIMcA6MzgViDBQ X-IronPort-AV: E=Sophos;i="4.75,637,1330923600"; d="scan'208";a="191967649" Received: from 76-10-182-35.dsl.teksavvy.com (HELO ceviche.home) ([76.10.182.35]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 22 Jun 2012 23:53:40 -0400 Received: by ceviche.home (Postfix, from userid 20848) id 52A3A660DC; Fri, 22 Jun 2012 23:49:46 -0400 (EDT) From: Stefan Monnier To: Michael Albinus Subject: Re: bug#11714: 24.1.50; find-file completion on a remote directory Message-ID: References: <87d350syld.fsf@gmx.de> Date: Fri, 22 Jun 2012 23:49:46 -0400 In-Reply-To: <87d350syld.fsf@gmx.de> (Michael Albinus's message of "Fri, 15 Jun 2012 11:39:42 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 11714-done Cc: 11714-done@debbugs.gnu.org, Dani Moncayo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) >> Recipe from "emacs -Q": >> 1. Eval: (cd "/some-user@some-host:~") >> 2. Give the correct password. >> 3. Type: C-x C-f / h o m e / s o m e - u s e r / t TAB I just fixed this in the trunk with the patch below. Stefan === modified file 'lisp/minibuffer.el' --- lisp/minibuffer.el 2012-06-18 20:39:52 +0000 +++ lisp/minibuffer.el 2012-06-23 03:46:25 +0000 @@ -488,7 +488,7 @@ (defun completion--twq-try (string ustring completion point unquote requote) - ;; Basically two case: either the new result is + ;; Basically two cases: either the new result is ;; - commonprefix1 morecommonprefix suffix ;; - commonprefix newprefix suffix (pcase-let* @@ -505,8 +505,13 @@ ((> point (length prefix)) (+ qpos (length qstr1))) (t (car (funcall requote point string)))))) ;; Make sure `requote' worked. - (assert (equal (funcall unquote qstring) completion)) - (cons qstring qpoint))) + (if (equal (funcall unquote qstring) completion) + (cons qstring qpoint) + ;; If requote failed (e.g. because sifn-requote did not handle + ;; Tramp's "/foo:/bar//baz -> /foo:/baz" truncation), then at least + ;; try requote properly. + (let ((qstr (funcall qfun completion))) + (cons qstr (length qstr)))))) (defun completion--string-equal-p (s1 s2) (eq t (compare-strings s1 nil nil s2 nil nil 'ignore-case))) @@ -2130,6 +2135,12 @@ ;; find the position corresponding to UPOS in QSTR, but ;; substitute-in-file-name can do anything, depending on file-name-handlers. ;; Kind of like in rfn-eshadow-update-overlay, only worse. + ;; FIXME: example of thing we do not handle: Tramp's makes + ;; (substitute-in-file-name "/foo:~/bar//baz") -> "/scpc:foo:/baz". + ;; FIXME: One way to try and handle "all" cases is to require + ;; substitute-in-file-name to preserve text-properties, so we could + ;; apply text-properties to the input string and then look for them in + ;; the output to understand what comes from where. (let ((qpos 0)) ;; Handle substitute-in-file-name's truncation behavior. (let (tpos) @@ -2824,14 +2835,14 @@ (defun completion--sreverse (str) "Like `reverse' but for a string STR rather than a list." - (apply 'string (nreverse (mapcar 'identity str)))) + (apply #'string (nreverse (mapcar 'identity str)))) (defun completion--common-suffix (strs) "Return the common suffix of the strings STRS." (completion--sreverse (try-completion "" - (mapcar 'completion--sreverse strs)))) + (mapcar #'completion--sreverse strs)))) (defun completion-pcm--merge-completions (strs pattern) "Extract the commonality in STRS, with the help of PATTERN. From debbugs-submit-bounces@debbugs.gnu.org Sat Jun 23 06:29:33 2012 Received: (at 11714) by debbugs.gnu.org; 23 Jun 2012 10:29:33 +0000 Received: from localhost ([127.0.0.1]:53547 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SiNav-0006F3-Dy for submit@debbugs.gnu.org; Sat, 23 Jun 2012 06:29:33 -0400 Received: from mailout-de.gmx.net ([213.165.64.23]:33039) by debbugs.gnu.org with smtp (Exim 4.72) (envelope-from ) id 1SiNas-0006Ev-Bu for 11714@debbugs.gnu.org; Sat, 23 Jun 2012 06:29:31 -0400 Received: (qmail invoked by alias); 23 Jun 2012 10:25:44 -0000 Received: from p57BB8B92.dip0.t-ipconnect.de (EHLO detlef.gmx.de) [87.187.139.146] by mail.gmx.net (mp035) with SMTP; 23 Jun 2012 12:25:44 +0200 X-Authenticated: #3708877 X-Provags-ID: V01U2FsdGVkX185HD8Ypys5yO2x9XfLHNe70kUat116jGL2VhQ68J Rj8aX12bNnCMzq From: Michael Albinus To: Stefan Monnier Subject: Re: bug#11714: 24.1.50; find-file completion on a remote directory References: <87d350syld.fsf@gmx.de> Date: Sat, 23 Jun 2012 12:25:42 +0200 In-Reply-To: (Stefan Monnier's message of "Fri, 22 Jun 2012 23:49:46 -0400") Message-ID: <87sjdmz5nd.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Y-GMX-Trusted: 0 X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 11714 Cc: 11714@debbugs.gnu.org, Dani Moncayo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) Stefan Monnier writes: > I just fixed this in the trunk with the patch below. That works, thanks! > + ;; FIXME: example of thing we do not handle: Tramp's makes > + ;; (substitute-in-file-name "/foo:~/bar//baz") -> "/scpc:foo:/baz". > + ;; FIXME: One way to try and handle "all" cases is to require > + ;; substitute-in-file-name to preserve text-properties, so we could > + ;; apply text-properties to the input string and then look for them in > + ;; the output to understand what comes from where. Shall I do action on Tramp? If yes, could this requirement to file name handlers be documented? > Stefan Best regards, Michael. From debbugs-submit-bounces@debbugs.gnu.org Sat Jun 23 10:02:06 2012 Received: (at 11714) by debbugs.gnu.org; 23 Jun 2012 14:02:06 +0000 Received: from localhost ([127.0.0.1]:54071 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SiQuc-0004F2-Ah for submit@debbugs.gnu.org; Sat, 23 Jun 2012 10:02:06 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.182]:40966) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SiQuZ-0004Ev-TQ for 11714@debbugs.gnu.org; Sat, 23 Jun 2012 10:02:04 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ai0FAG6Zu09FxLSN/2dsb2JhbABEsEiDSYEIghYBBScvIxALNBIUGA0kiCG6CZBEA6MzgViDBQ X-IronPort-AV: E=Sophos;i="4.75,637,1330923600"; d="scan'208";a="191979460" Received: from 69-196-180-141.dsl.teksavvy.com (HELO pastel.home) ([69.196.180.141]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 23 Jun 2012 09:58:18 -0400 Received: by pastel.home (Postfix, from userid 20848) id 402524E213; Sat, 23 Jun 2012 09:58:18 -0400 (EDT) From: Stefan Monnier To: Michael Albinus Subject: Re: bug#11714: 24.1.50; find-file completion on a remote directory Message-ID: References: <87d350syld.fsf@gmx.de> <87sjdmz5nd.fsf@gmx.de> Date: Sat, 23 Jun 2012 09:58:18 -0400 In-Reply-To: <87sjdmz5nd.fsf@gmx.de> (Michael Albinus's message of "Sat, 23 Jun 2012 12:25:42 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -1.9 (-) X-Debbugs-Envelope-To: 11714 Cc: 11714@debbugs.gnu.org, Dani Moncayo X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.9 (-) >> + ;; FIXME: example of thing we do not handle: Tramp's makes >> + ;; (substitute-in-file-name "/foo:~/bar//baz") -> "/scpc:foo:/baz". >> + ;; FIXME: One way to try and handle "all" cases is to require >> + ;; substitute-in-file-name to preserve text-properties, so we could >> + ;; apply text-properties to the input string and then look for them in >> + ;; the output to understand what comes from where. > Shall I do action on Tramp? If yes, could this requirement to file name > handlers be documented? No, we'd probably have to add a new file-name operation for that, or change the requirements of substitute-in-file-name as suggested. But if that will happen, it won't be before the next round of completion changes. Stefan From unknown Wed Aug 20 04:12:10 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 22 Jul 2012 11:24:03 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator