From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id SI93FVVziWOXDAEAbAwnHQ (envelope-from ) for ; Fri, 02 Dec 2022 04:39:01 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id gAKMFFVziWPvgAEAG6o9tA (envelope-from ) for ; Fri, 02 Dec 2022 04:39:01 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 2EAB63EECF for ; Fri, 2 Dec 2022 04:39:01 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p0wsP-0003Tb-Q2; Thu, 01 Dec 2022 22:38:13 -0500 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 1p0wsO-0003TR-NK for emacs-orgmode@gnu.org; Thu, 01 Dec 2022 22:38:12 -0500 Received: from out2.migadu.com ([188.165.223.204]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p0wsM-0006aQ-FS; Thu, 01 Dec 2022 22:38:12 -0500 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Kyle Meyer To: Bastien Cc: emacs-orgmode@gnu.org Subject: Re: [PATCH] Autoload `org-assert-version' and remove org-loaddefs.el In-Reply-To: <87bkonzisl.fsf@gnu.org> Date: Thu, 01 Dec 2022 22:38:03 -0500 Message-ID: <874juewk4k.fsf@kyleam.com> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=188.165.223.204; envelope-from=kyle@kyleam.com; helo=out2.migadu.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-TUID: PqA02AWDb/mo Bastien writes: > Some users reported an (invalid-function org-assert-version) error > when installing Org from ELPA: > > https://lists.sr.ht/~bzg/emacsfr/%3Cd091463e1615422eb00070727d6a094ec0ae3c73.camel%40adocentyn.io%3E > https://www.reddit.com/r/emacs/comments/z7qulo/comment/iyd9vam/?context=3 > > This patch autoloads `org-assert-version'. I don't understand the rationale behind this. Every spot that calls org-assert-version is preceded by a line that requires org-macs, so isn't this error likely due to a mixed installation/load-path issue where the wrong/older org-macs is taking precedence? > It also removes the ;; generated-autoload-file: "org-loaddefs.el" > footer in all files and let Make create org-autoloads.el instead. I'm worried with how this will play with the Org bundled with Emacs. The autoloads that are now written to lisp/org/org-loaddefs.el will instead pollute the top-level lisp/loaddefs.el. When I tested this out in the Emacs repo, running `make` shows many lines of WARNING: No org-autoloads.el file could be found from where org.el is loaded. and You need to run "make" or "make autoloads" from Org lisp directory during the build. And loading/using Org shows the same. > Before the patch, installing from ELPA creates both org-loaddefs.el > and org-autoloads.el, which is confusing. Hmm, isn't this in line with the lisp/org-loaddefs.el and lisp/loaddefs.el split that happens for the Emacs repo? A similar split is used other packages in the Emacs repo as well: $ find lisp | grep '\-loaddefs.el' | head lisp/ps-print-loaddefs.elc lisp/org/org-loaddefs.el lisp/org/org-loaddefs.elc lisp/net/tramp-loaddefs.el lisp/net/tramp-loaddefs.elc lisp/calc/calc-loaddefs.el lisp/calc/calc-loaddefs.elc lisp/textmodes/reftex-loaddefs.el lisp/textmodes/reftex-loaddefs.elc lisp/textmodes/texinfo-loaddefs.elc $ find lisp | grep -c '\-loaddefs.el' 29 $ find lisp | grep -c '\-autoloads.el' 0 And with the port of Emacs's 2682ea1b3 (Org commit 19c3969e7, 2022-10-04), there's also one spot that uses ;;;###org-autoload, which tells loaddefs-gen.el to direct the autoload to org-loaddefs.el. > Unless anyone objects, I'll install this patch in the bugfix branch > tomorrow and release 9.6.1. I think as is the patch would cause issues, and more generally I'm not convinced we should be moving away from having an org-loaddefs.el file. I'm also concerned about this sort of tree-wide change in a patch release that will be synced to the emacs-29 branch. Thanks for posting this for discussion, and please let me know if I'm mistaken about the interaction with the Emacs repo.