From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Daniel Mendler Newsgroups: gmane.emacs.bugs Subject: bug#49776: 28.0.50; Incorrect username completion results reported by `read-file-name-interal` Date: Fri, 30 Jul 2021 15:22:18 +0200 Message-ID: <4bd7f6ed-5e65-af35-1952-501a45fce8f1@daniel-mendler.de> References: <82d07cfd-a345-bf79-0fd4-4386ce2fe381@daniel-mendler.de> <87bl6kowfo.fsf@gnus.org> <48dff852-4ba9-730f-54c9-6800dffe9e8f@daniel-mendler.de> <8735rwm0ec.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9837"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 49776@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Jul 30 15:24:03 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m9SUc-0002GV-5O for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 30 Jul 2021 15:24:02 +0200 Original-Received: from localhost ([::1]:55010 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m9SUa-0001SS-RX for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 30 Jul 2021 09:24:00 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53536) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m9STe-0000Jj-Gz for bug-gnu-emacs@gnu.org; Fri, 30 Jul 2021 09:23:05 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:47873) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m9STe-0006PO-9j for bug-gnu-emacs@gnu.org; Fri, 30 Jul 2021 09:23:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1m9STe-0001lp-71 for bug-gnu-emacs@gnu.org; Fri, 30 Jul 2021 09:23:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Daniel Mendler Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 30 Jul 2021 13:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49776 X-GNU-PR-Package: emacs Original-Received: via spool by 49776-submit@debbugs.gnu.org id=B49776.16276513486750 (code B ref 49776); Fri, 30 Jul 2021 13:23:02 +0000 Original-Received: (at 49776) by debbugs.gnu.org; 30 Jul 2021 13:22:28 +0000 Original-Received: from localhost ([127.0.0.1]:59419 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m9ST6-0001ko-GV for submit@debbugs.gnu.org; Fri, 30 Jul 2021 09:22:28 -0400 Original-Received: from server.qxqx.de ([178.63.65.180]:54045 helo=mail.qxqx.de) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m9ST4-0001ka-CF for 49776@debbugs.gnu.org; Fri, 30 Jul 2021 09:22:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=qxqx.de; s=mail1392553390; h=Content-Transfer-Encoding:Content-Type:In-Reply-To: MIME-Version:Date:Message-ID:From:References:Cc:To:Subject:Sender:Reply-To: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=H/FjDmypD3zFs54M2L5Use7b69M0P/imvJYdVPTlnsU=; b=RQwEXdY+UTbnFc5KPMtPQNsQZO hq1pQQmcz7YbO3Yun7azJ5sOpKn8WlX7L48FLKLWH+LHexE0ZIK6ZzfsusNkMQviDmIS4703RcCfK 5Tvl7CG+iuX7LCBEacYxW+yb+XUL+URpbyciUJ9Ar+sqnvIqChQUdyuxfhLyguiD6HGw=; In-Reply-To: <8735rwm0ec.fsf@gnus.org> Content-Language: en-US X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:210909 Archived-At: On 7/30/21 2:50 PM, Lars Ingebrigtsen wrote: > But you said it returned "/.config/~man" for you (while it returns > "/.config/~man/" for me) (note trailing slash)... Yes, this was a typo from my side, sorry for that. Please look at the other examples I've sent. So to describe this better: (all-completions "~/etc/~man" 'read-file-name-internal) returns ("/etc/~man/"). In contrast (all-completions "/usr/~man" 'read-file-name-internal) returns ("man/"). "/etc/~man/ is neither a valid user name nor a valid file path. I have the user "man" on my system of course (I am also on a recent Debian). So the problem here is that in to even call the completion table with "~/etc/~man", the completion boundary is placed such that the string behind the first "~" is completed. If I read Eli correctly, he says that this is the expected behavior, while I would have expected that the completion boundary is placed behind the second "~", such that the completion table does not return odd looking results like "/etc/~man". Furthermore the string before the first "~" can be considered shadowed. So maybe the problem here is not with the results returned by `all-completions` but rather with the completion boundaries. I think this needs further investigation from my side. Daniel