From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Simon Tournier Newsgroups: gmane.emacs.bugs Subject: bug#57407: closed (Re: bug#57407: [PATCH] Handle error of =?UTF-8?Q?=E2=80=99vc-registered=E2=80=99?=) Date: Mon, 10 Jun 2024 16:03:06 +0200 Message-ID: <87sexkj3ol.fsf@gmail.com> References: <87lercwb0o.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="2174"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 57407@debbugs.gnu.org To: stefankangas@gmail.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jun 18 16:05:20 2024 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 1sJZSa-0000MT-OQ for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 18 Jun 2024 16:05:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sJZSH-0005ID-HJ; Tue, 18 Jun 2024 10:05:01 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sJZSF-0005Hg-8v for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2024 10:04:59 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sJZSF-0003Ra-0p for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2024 10:04:59 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sJZSH-0004Qj-KW for bug-gnu-emacs@gnu.org; Tue, 18 Jun 2024 10:05:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Simon Tournier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 18 Jun 2024 14:05:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57407 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch moreinfo Original-Received: via spool by 57407-submit@debbugs.gnu.org id=B57407.171871947616984 (code B ref 57407); Tue, 18 Jun 2024 14:05:01 +0000 Original-Received: (at 57407) by debbugs.gnu.org; 18 Jun 2024 14:04:36 +0000 Original-Received: from localhost ([127.0.0.1]:43812 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sJZRr-0004Ps-Hp for submit@debbugs.gnu.org; Tue, 18 Jun 2024 10:04:35 -0400 Original-Received: from mail-wr1-f51.google.com ([209.85.221.51]:41851) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sJZRm-0004PN-37 for 57407@debbugs.gnu.org; Tue, 18 Jun 2024 10:04:31 -0400 Original-Received: by mail-wr1-f51.google.com with SMTP id ffacd0b85a97d-35904026d72so508428f8f.3 for <57407@debbugs.gnu.org>; Tue, 18 Jun 2024 07:04:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718719401; x=1719324201; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=gqNvUyV/GsbsKo76uPmgytm0bX0Q+uym7oiMcjc0T9w=; b=GEgHAFN3eqKX3t8W8vIfyayc1itO/JrrmTZ3j0y13qRmS41wHYoMC0CSv5bZnKXRkS 1uRZtvGGUlpne0f3hxXqtoAGXgS0bg8nzKr8fuzRZixdiw/AJ+AWe2RgzWmSwJ2BDoqx /v/QfSH+Ypl1O0RV47SF1Htl6BorWBSJPviBoMbDFOU66tcijP6ZUv/glyrXq1Fji028 rQmB7x+nn672wwHtkFWDhUujipmATNQGU+TxL8JVJHLW4P2W5N/oPYc45hsRF9mzRsH4 GUU75k8jwqnDeQWpUMGMpMoMd7Lvag0MSKhMUW720kkQKgM+7tQ0yhR92Zi2qPc6QxU+ S1AQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718719401; x=1719324201; h=content-transfer-encoding:mime-version:user-agent:message-id:date :references:in-reply-to:subject:cc:to:from:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=gqNvUyV/GsbsKo76uPmgytm0bX0Q+uym7oiMcjc0T9w=; b=fUDiZ02ya/tzMXhCgHNyiHtM+76c53IRZmGTBdL++q1aSgWnDZZROqp+5542Y31ovz 7bytrBMZuDToh/VrPUrbhAhCa9k2zLqZAkZNpwiyRJuFSEXdmogk6rqoGsmIRHJQIbfR ANyQok6iKEKps2FRuIzoEEPZb1WTINifIZrgNNyKJw/IEUrr+EAEnxsuj/Qf0uvy7sXN ioTsR2sCKCXLlG+d76bOXM9JscL83D7Uh21YOGWaY6EQk14XazuYZIYgmfGaH6jync+b rGaoXXhJhoQzufJGQs5GuBeTQrnfhNzCEe/uvzCGUdxwj99fcc6hL3siBmu51/3IiHf4 8dZQ== X-Gm-Message-State: AOJu0YxTlfW+cjkT9VL0Xl3TU/Z1Ha2jg3z11i2C2Xjk2eeSyVBpHX0D qeCw2Sr0KClBE/sm/XrLx7Gz0JA1uxwDNvWhjUSW/vX6kJ96zUWL8NoQmw== X-Google-Smtp-Source: AGHT+IE6Go/WCo1N7F5yphDRJKuDWGMbLo9WxjvRSch8rQYQqR9lEY5T3z1QEoyHAvBQcYi13Y4Whg== X-Received: by 2002:a5d:64e9:0:b0:35f:2929:8432 with SMTP id ffacd0b85a97d-3607a720568mr10328011f8f.2.1718719401543; Tue, 18 Jun 2024 07:03:21 -0700 (PDT) Original-Received: from lili ([131.254.253.81]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-360750f2295sm14233813f8f.82.2024.06.18.07.03.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Jun 2024 07:03:21 -0700 (PDT) In-Reply-To: (GNU bug Tracking System's message of "Sun, 09 Jun 2024 22:18:02 +0000") 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:287441 Archived-At: Hi, On Sun, 09 Jun 2024 at 22:18, help-debbugs@gnu.org (GNU bug Tracking System= ) wrote: >> That was one year ago. >> >> Simon, did you have a chance to look into the issues that Dmitry >> mentioned below? > > More information was requested, but none was given within 9 months, so > I'm closing this bug. If this is still an issue, please reply to this > email (use "Reply to all" in your email client) and we can reopen the > bug report. The issue is not gone, AFAICT. The cover letter provides a reproducer; see below. > From: Simon Tournier > Subject: [PATCH] Handle error of =E2=80=99vc-registered=E2=80=99 > To: bug-gnu-emacs@gnu.org > Date: Thu, 25 Aug 2022 18:20:07 +0200 > Date: Thu, 25 Aug 2022 18:20:07 +0200 (1 year, 41 weeks, 2 days ago) > > Hi, > > Submission (Bug#18481) [0] merged on 2020-08-13 with commit > 991e145450ec8b02865597bc80fd797e39e81f07 [1] aims to: > > =E2=80=9CNotify the user if we errors when querying for registered git fi= les=E2=80=9C > > However, the replacement of =E2=80=99ignore-errors=E2=80=99 by =E2=80=99w= ith-demoted-errors=E2=80=99 > introduces spurious messages. This patch proposes to handle the errors > in a way that: > > 1. the user is still informed (avoid silent error) > 2. improve the messages trying to be more accurate > 3. do it for all the VC backends > > 0: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D18481 > 1: > https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=3D991e145450ec8b02= 865597bc80fd797e39e81f07 > > > > First, let compare the previous situation with the patched one. If the > user runs =E2=80=99find-file=E2=80=99 in a Git repository without having = installed the > Git binary, then Emacs complains and the error is misleading. > Reproducer: > > $ which git > which: no git in =E2=80=A6 > $ mkdir -p /tmp/Git/.git > $ emacs -q --batch --eval=3D"(find-file \"/tmp/Git/foo\")" > Error: (file-missing "Searching for program" "No such file or directory" = "git") > Package vc-mtn is deprecated > > > Not having a working Git installation is not an error for opening one > file belonging to a folder containing a =E2=80=99.git=E2=80=99 subdirecto= ry. For > instance, if an user processes many files reporting many messages, then > it seems hard to locate the real error, if any. > > > Moreover, the messages are inconsistent depending on the VC backend; > from nothing reported to a backtrace. > > $ mkdir -p /tmp/Bzr/.bzr > $ emacs -q --batch --eval=3D"(find-file \"/tmp/Bzr/foo\")" > Error: (file-missing "Searching for program" "No such file or directory" = "bzr") > Error: (file-missing "Searching for program" "No such file or directory" = "bzr") > > Error: file-missing ("Searching for program" "No such file or directory" = "bzr") > > [...] > > Searching for program: No such file or directory, bzr Well, I am not following very closely the development of Emacs master, so I cannot tell with high confidence if a workaround introduced elsewhere fixes the issue. However, from my quick look, the code that triggers the spurious messages has not been changed. Sorry to not have the time to send a v2; I am running out of time. However, closing this report: 1. Do not change that 991e145450ec8b02865597bc80fd797e39e81f07 is clearly incorrect. It=E2=80=99s a regression 2. My patch, while imperfect, fixes such regression. Cheers, simon