From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#62762: 'make' often errors with "Org version mismatch" after pulling a new version of the code Date: Sun, 07 May 2023 17:57:37 -0400 Message-ID: References: <17b74a48-94e1-9106-cc79-d31972313910@gutov.dev> <87wn2ilwed.fsf@localhost> <83zg7ealrd.fsf@gnu.org> <87pm8a8dx4.fsf@localhost> <87pm7vt0mx.fsf@localhost> <87cz3k8i27.fsf@localhost> <87sfcfdldt.fsf@localhost> <87bkj1g10g.fsf@localhost> <1c5d0ff0-5bae-1123-d2f7-64d9013fbc0f@gmail.com> <6070e598-7dee-1b7a-7f97-26a90618cb7a@gmail.com> <5603ba14-8120-cf38-05ba-4435c1bece3f@gmail.com> <03d0e4f4-3855-fa3e-d502-bee77ea53b74@gmail.com> Reply-To: Stefan Monnier Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7517"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Ihor Radchenko , 62762@debbugs.gnu.org, bzg@gnu.org, dmitry@gutov.dev, Alan Mackenzie , Eli Zaretskii To: Max Nikulin Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun May 07 23:58:24 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 1pvmOd-0001ij-Ke for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 07 May 2023 23:58:24 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pvmOL-0006QV-6l; Sun, 07 May 2023 17:58:05 -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 1pvmOJ-0006Q5-3l for bug-gnu-emacs@gnu.org; Sun, 07 May 2023 17:58: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 1pvmOI-0003tH-Rf for bug-gnu-emacs@gnu.org; Sun, 07 May 2023 17:58:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pvmOI-0005o2-B4 for bug-gnu-emacs@gnu.org; Sun, 07 May 2023 17:58:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 07 May 2023 21:58:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62762 X-GNU-PR-Package: emacs Original-Received: via spool by 62762-submit@debbugs.gnu.org id=B62762.168349666822296 (code B ref 62762); Sun, 07 May 2023 21:58:02 +0000 Original-Received: (at 62762) by debbugs.gnu.org; 7 May 2023 21:57:48 +0000 Original-Received: from localhost ([127.0.0.1]:38638 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pvmO4-0005nX-0E for submit@debbugs.gnu.org; Sun, 07 May 2023 17:57:48 -0400 Original-Received: from mailscanner.iro.umontreal.ca ([132.204.25.50]:47958) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pvmO1-0005nK-Tf for 62762@debbugs.gnu.org; Sun, 07 May 2023 17:57:46 -0400 Original-Received: from pmg1.iro.umontreal.ca (localhost.localdomain [127.0.0.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 9DC2B10011A; Sun, 7 May 2023 17:57:40 -0400 (EDT) Original-Received: from mail01.iro.umontreal.ca (unknown [172.31.2.1]) by pmg1.iro.umontreal.ca (Proxmox) with ESMTP id 2E4641000E7; Sun, 7 May 2023 17:57:39 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=iro.umontreal.ca; s=mail; t=1683496659; bh=Btudk+tiaGlf7/lcFqBlmVgNgJz9Y05EdtEhbvdRXJ8=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=mQfdeiLkJ/rEvJ3KLyEuqxCjvsfJHuCbMll9dlB+8N8DRc4t/Wadaob9cPAYslTEy x9FVmrWGjqceGnqUnG+oVBS/ux5ZRSWaH1Gw3bdsWS6vR5kwMHiyfu0bz+PKGLR39x BCZDHtcFWCvd6lDWe45UHzjpjUeYjEIUeexSLrb5uOLhD8mSar0YpMnzVp97Sid/I9 dHHfW3Vpas3bqG8L0c9BBU+EV+4r9WCxHEKylpx0VHiob7hDxohYqOyLnbrY+I4xIb Auoib+w7yAF6wLknDXveuOf9lHnpRODo5ZKyBAuTZkQtRS3wMdhwaot2LkEnL1TyYq V+q+tTcWwIf9w== Original-Received: from pastel (unknown [45.72.217.176]) by mail01.iro.umontreal.ca (Postfix) with ESMTPSA id E275B1201CB; Sun, 7 May 2023 17:57:38 -0400 (EDT) In-Reply-To: <03d0e4f4-3855-fa3e-d502-bee77ea53b74@gmail.com> (Max Nikulin's message of "Sun, 7 May 2023 23:23:15 +0700") 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:261280 Archived-At: >> AFAIU there are 2 main situations: >> A) recompilation (i.e. `git pull; make`). >> This can happen either in Org's repository or in Emacs's repository. > ... > Are there brave enough developers and users who do not restart emacs after > rebuild of Emacs? I recompile daily, and restart every other month or so? FWIW, I never bumped into a problem with Org due to that (and never used `org-reload` either). >> B) mixed versions from different directories. >> AFAICT `my-require-with-shadow-check` should be able to catch most/all >> problems for (B), > > Agree. > >> without impacting (A), and more reliably than >> `org-assert-version` (and in an arguably less ad-hoc way). > > Sorry, but `org-assert-version' should catch loading from the same directory > a file compiled for new version since loaded earlier org-version.el defined > old version that does not match `org-version' inscribed into new .elc > files. I assume either combination of "make clean" and "make" or proper > incremental build. I'd consider these scenarios to fall into (A) or thereabout. And users who do like I do (i.e. recompile Org while a session is using those Org files) get what they deserve if they encounter a problem. We have so many more real problems that I'm not interested in considering such cases. I can give you a life-long supply of further hypothetical cases if you're so inclined :-) > By the way, if just org-macs should be checked then would not be it more > efficient in respect to load time to define a variable containing the > directory and to check in other files if they are loaded from the same > directory? With such approach there is no need in walking through the > `load-history' list. You might be right. I was thinking in more general terms (e.g. I'm thinking that maybe a test along the lines of the one performed by `my-require-with-shadow-check` could be (optionally) included in `require`). Stefan