From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#62734: Always fully rebuild autoloads in package-generate-autoloads Date: Fri, 28 Apr 2023 18:48:38 +0300 Message-ID: <83pm7oqa7d.fsf@gnu.org> References: <87lej2oz14.fsf@le0.gs> <874jp0aw7h.fsf@posteo.net> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32172"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 62734@debbugs.gnu.org, leo.gaskin@le0.gs To: Philip Kaludercic Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Apr 28 17:49:16 2023 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 1psQLU-00088F-Sw for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 28 Apr 2023 17:49:16 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1psQLI-0006ce-OJ; Fri, 28 Apr 2023 11:49:04 -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 1psQLH-0006b5-AD for bug-gnu-emacs@gnu.org; Fri, 28 Apr 2023 11:49:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1psQLG-0002xK-UY for bug-gnu-emacs@gnu.org; Fri, 28 Apr 2023 11:49:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1psQLG-00082K-BA for bug-gnu-emacs@gnu.org; Fri, 28 Apr 2023 11:49:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 28 Apr 2023 15:49:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62734 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 62734-submit@debbugs.gnu.org id=B62734.168269689530754 (code B ref 62734); Fri, 28 Apr 2023 15:49:02 +0000 Original-Received: (at 62734) by debbugs.gnu.org; 28 Apr 2023 15:48:15 +0000 Original-Received: from localhost ([127.0.0.1]:34273 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1psQKU-0007zw-Jw for submit@debbugs.gnu.org; Fri, 28 Apr 2023 11:48:15 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:52596) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1psQKR-0007yw-1L for 62734@debbugs.gnu.org; Fri, 28 Apr 2023 11:48:13 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1psQKK-0002su-Pk; Fri, 28 Apr 2023 11:48:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=QYwVjnDoG/mO/7tI2QgHBqPPOlEqmwR/luNXqltxLQI=; b=W8eVF0TJ4+SB daNCVbguOzLNZg6DbISLizgadiuidp6MLAY3qdikkwcyT4PYCM4ym8zV6QcLTZJF7WFIulEcluYzI a5zpQLyIMQBQbLhjUyBWp4fzkB8zL6mV+LpJ51BgllbT0KS+qU9NMqOx/iuxKW8rQrAbH1ZUK0Hln wK4Zzz07ixW/5LuD2ESPJ30cBEW+x8UL+Qk05zoW+L2ih0y2ZhZwxRzZgOTMwIXOWlQFnn1P0t3TV NCTDYccqQ4tXUpicuiXsipXYyP2fhCDcRdxXXfvi0o4oF3hcYbjGktYg1AmPw/hu+b7jAlcgseIE0 OX7tDT+EEWQFoRCE0CVumg==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1psQKK-0002fL-3T; Fri, 28 Apr 2023 11:48:04 -0400 In-Reply-To: <874jp0aw7h.fsf@posteo.net> (message from Philip Kaludercic on Fri, 28 Apr 2023 15:00: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:260781 Archived-At: > From: Philip Kaludercic > Cc: 62734@debbugs.gnu.org, "'Eli Zaretskii'" > Date: Fri, 28 Apr 2023 15:00:02 +0000 > > Leo Georg Gaskin writes: > > > Tags: patch > > > > Hello! > > > > I've been using the new package-vc.el functionality to great effect, > > but I have also come across a somewhat annoying bug. If I use any of > > the provided commands to rebuild my local package while a autoloads > > file is already present, the newly generated autoloads file is > > consistently either incomplete or empty. > > > > The easiest way I've found to fix this is simply changing the > > `package-generate-autoloads' function to always rebuild the autoloads > > file by passing the relevant option to `loaddefs-generate'. I think > > this change also makes sense on a larger scale, as package generation > > taking into account older build artifacts seems unintuitive. > > > > The attached patch implements this change. > > > > I've read that for small changes like this no copyright assignment > > is needed. If I have misunderstood, please point me to the relevant > > documents so I can sign them. Please also let me know if I have > > messed something up or you need any additional information. > > It seems to me that your fix is the easiest way to tackle the issue, > without having to do a deep-dive into loaddefs. Eli, can this be > applied to emacs-29? An alternative fix would be to restrict the > changes to package-vc, but that seems like an unnecessary duplication, > since the change doesn't affect package. I don't understand the original problem (what does package-vc.el have to do with rebuilding local packages? and why is a newly generated loaddefs file incomplete or empty?), and I certainly don't think I understand the effects of this change on the other usage scenarios. Why would we want to unconditionally rebuild all the loaddefs files every time package-generate-autoloads is invoked? OTOH, that function is not really documented, so maybe I don't understand what is it supposed to do and in which conditions. IOW, I think we need more details about the problem and the proposed solution.