From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Philip Kaludercic Newsgroups: gmane.emacs.bugs Subject: bug#73102: 29.4; `package-recompile-all' should skip packages installed by distro package manager Date: Sun, 08 Sep 2024 10:42:35 +0000 Message-ID: <87tteqe89w.fsf@posteo.net> References: <87bk0z37qf.fsf@localhost> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1918"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 73102@debbugs.gnu.org To: Zhengyi Fu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Sep 08 12:43:15 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 1snFNy-0000Nk-RD for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 08 Sep 2024 12:43:15 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1snFNl-0005ie-JC; Sun, 08 Sep 2024 06:43: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 1snFNj-0005iM-TX for bug-gnu-emacs@gnu.org; Sun, 08 Sep 2024 06:42: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 1snFNj-0001uV-K6 for bug-gnu-emacs@gnu.org; Sun, 08 Sep 2024 06:42:59 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=oVL1qptdJvpca5aSVicmHe0rCBffru9A/oGUOaXMgj0=; b=gLNInOMeAbCzS0lJSMS7FqLtPxpLYmBZfMNoePrv39ivpMNAWh6MnBOAZdtq5tL417cay6EuPw5M3sa7zNr2oirb4zjOOzPEzvXVd+5/S6wz3ictGjKK1m/Tr7bIadM3uHlwHOTEQQItHkh/YcidgST7jo4qOkJzgfLADZlyT40pjxAUa1g/v/9YTpdC7FHAagC/XB5AohT5QCfV+82I3jgrYXZV8JFJKnYMiWd/8LnIa9nJJgrITj53mHQdXiDmqV6f8QDhnccxYYnL6Oowa04NILdIz6phO0EnCShjLCJahPNsCVmMy5BuEzEDQpVSngPLOv75iAD4bMOyNr/i/g==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1snFNl-0004NW-KZ for bug-gnu-emacs@gnu.org; Sun, 08 Sep 2024 06:43:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Philip Kaludercic Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 08 Sep 2024 10:43:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73102 X-GNU-PR-Package: emacs Original-Received: via spool by 73102-submit@debbugs.gnu.org id=B73102.172579216716808 (code B ref 73102); Sun, 08 Sep 2024 10:43:01 +0000 Original-Received: (at 73102) by debbugs.gnu.org; 8 Sep 2024 10:42:47 +0000 Original-Received: from localhost ([127.0.0.1]:58013 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1snFNX-0004N1-3o for submit@debbugs.gnu.org; Sun, 08 Sep 2024 06:42:47 -0400 Original-Received: from mout01.posteo.de ([185.67.36.65]:58661) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1snFNV-0004Mk-7K for 73102@debbugs.gnu.org; Sun, 08 Sep 2024 06:42:46 -0400 Original-Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id ADDDD240027 for <73102@debbugs.gnu.org>; Sun, 8 Sep 2024 12:42:36 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1725792156; bh=SCP0oNy+jbNae6sGoedkUWFYZIsJAfhR7LUy4PIjmRk=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=dHEvTDArWsFMnHz8xZIoofBxeBkmQHmKiWHvbPDsDU91q2yddRzNoCa2QZad/6pqh yI4PUIPDEK2+dTAoR0l65YdIbfQS/RjTBphFGEHG/naU5LTZxitxzpFLSaOESq5eud pWqbGQHC6Ock7x+6x4d3+Ulf5n9waZHZtAOITM0ZQXzyy1dnEqL2TSMyst1DLOmc5J OiWD9n48Bigre7dKPjaHZQXQC2ZltTaowpdGX6WqYYZXT+KsiRIGVPWabZ+k8cNTQr 7AUNn/c2ZaWNTmljC25nlxLj4m6H72AkFsHZ8T/mDddA4ltikQKSixUI3AXh2hOWIs +nMzZ8m5LSxkQ== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4X1mkh0FY4z9rxS; Sun, 8 Sep 2024 12:42:35 +0200 (CEST) In-Reply-To: <87bk0z37qf.fsf@localhost> (Zhengyi Fu's message of "Sat, 07 Sep 2024 21:37:28 +0800") X-Hashcash: 1:20:240908:i@fuzy.me::A4VLgTy5sbBabWxQ:rQT X-Hashcash: 1:20:240908:73102@debbugs.gnu.org::KX+XdM83A/e6ZQRM:8D/5 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:291433 Archived-At: Zhengyi Fu writes: > When I try recompiling all packages installed by package.el with `M-x > package-recompile-all', I got the following error: > > Debugger entered--Lisp error: (permission-denied "Removing old name" "Permission denied" "/usr/share/emacs/site-lisp/elpa/mu4e-1.10.8/mu4e-a...") > package-recompile(#s(package-desc :name mu4e :version (1 10 8) :summary "the mu mail user agent" :reqs nil :kind nil :archive nil :dir "/usr/share/emacs/site-lisp/elpa/mu4e-1.10.8" :extras nil :signed nil)) > package-recompile-all() > funcall-interactively(package-recompile-all) > command-execute(package-recompile-all record) > execute-extended-command(nil "package-recompile-all" "recom all") > funcall-interactively(execute-extended-command nil "package-recompile-all" "recom all") > command-execute(execute-extended-command) > > This is possibly because the package `mu4e' was installed by the distro > package manager in a path where normal users don't have write access. > > I think `package-recompile-all' should either skip those packages that > are not installed by package.el or ignore such errors and continue to > recompile other packages. We have installed a patch in Bug#68678 on master (the commit is from last February, so you wouldn't see it yet on 29.4) that wraps the `package-recompile' call in a `with-demoted-errors' block. That would still emit a error message, but it wouldn't break the recompilation procedure. Do you think that is enough, or should be explicitly and additionally avoid re-compiling external packages? -- Philip Kaludercic on icterid