GNU bug report logs - #57972
29.0.50; Autoloaded function raises (void-function org-element-cache-reset) when called within major-mode body

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Reported by: Ihor Radchenko <yantar92@HIDDEN>; dated Wed, 21 Sep 2022 08:34:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 14:09:44 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 10:09:44 2022
Received: from localhost ([127.0.0.1]:34912 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1ob0Q4-0000sc-5b
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 10:09:44 -0400
Received: from mail-lf1-f45.google.com ([209.85.167.45]:37863)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <yantar92@HIDDEN>) id 1ob0Q2-0000sP-Hi
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 10:09:42 -0400
Received: by mail-lf1-f45.google.com with SMTP id k10so9426331lfm.4
 for <57972 <at> debbugs.gnu.org>; Wed, 21 Sep 2022 07:09:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:from:to:cc:subject:date;
 bh=kRfMjElqdpuFKs2Ev7N+QgFk73krMUEQ78DTBAtPHKw=;
 b=HqmgbWRF0aAfHrR8Z4cH0QnAs1FXacQeVKR0o68T5i6w/9EUC2Dp3CTilflYEe406v
 QA90wY+uVEqw8vT9e0JxeAay7FYyaUs2ijoUtzC1LbQGiYUUgW0XOKNAr7EbWfOkxLTb
 65bxHjnbV9vEsox13tZba2D0Q/KL2zg9MfzEP2DzlgHCLpaBsoTpCvPRqq/t2BnoWFRu
 Ey6NkbCUTMIZ8EzcBKA6ebyiBHyL8qs/dl/tFza58czsAWCUt9sMm+CRkwOUxuymfKC+
 klFwEaYiQvyMZSdf0nAPB4XosfFzytq7hbBhi43xiQXmn8gzFb/y47q27hVYYMeYeH38
 GpVw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:x-gm-message-state:from:to:cc:subject:date;
 bh=kRfMjElqdpuFKs2Ev7N+QgFk73krMUEQ78DTBAtPHKw=;
 b=dkt567UUYYeoVH7vIMqHMLRHojrQ3F/xEhfNteotrfZJ78eYlIgAaT7tixUTGO+ZCE
 gowp39ZSBHTUPzXwTXQwgMcSpmgesQg0hNg5+QdgCimiQNKOFg8ENf5b/m5pbULCbjUI
 mdlbmIWIVEu5emX88eWDhVjVThp4/A0vZI0zu2bsoKKySd8BG+IdGooCSSdg8OUFEMcY
 jmHYaecWpdOKmosA7IUVd9NOKC33SKqfCnHZTT0SlfpC8XEziIe2Fm/m+mYosmjgcL75
 BNzvIoon+lPryFJMrWgLFzkCwKxZumKN4Pi49owliTcX0sK88Snk88UH322TzCVl5vjN
 TVXw==
X-Gm-Message-State: ACrzQf2HuTbTFa4/A24/bruvAS4nGWL+sEir49gTCLevGq82DTT33CfW
 3mYh2FaJKlqJgnpCypJWIAQf7baLAKNUW/3coJgP/oOFTLw=
X-Google-Smtp-Source: AMsMyM7ZjygcVl8XAMQ/KjIe7JiU0k4TMtzE+lVfnsXKLHmKmhdLW1eIRsSYzUfxtGv1GKDyoY7AiHdCSihE7JJJh40=
X-Received: by 2002:ac2:544a:0:b0:49f:4ecb:178d with SMTP id
 d10-20020ac2544a000000b0049f4ecb178dmr9739372lfn.663.1663769376513; Wed, 21
 Sep 2022 07:09:36 -0700 (PDT)
MIME-Version: 1.0
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <83edw4vqsq.fsf@HIDDEN>
 <CACnOyihWEN+WTA17ijKSSW8SrN=8cD16TP=U-58yq+9sJPL-mQ@HIDDEN>
 <838rmcvphe.fsf@HIDDEN>
 <CACnOyiifySWH8njQBSLpBoGQzdxdqS7CPC47cEkCur5YSwXkkg@HIDDEN>
 <8335ckvn5p.fsf@HIDDEN>
In-Reply-To: <8335ckvn5p.fsf@HIDDEN>
From: Ihor Radchenko <yantar92@HIDDEN>
Date: Wed, 21 Sep 2022 22:10:24 +0800
Message-ID: <CACnOyijgecMXTtNGWM3v8fbD65a0=VM8urTznKqMFTPN9x+z_g@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
To: Eli Zaretskii <eliz@HIDDEN>
Content-Type: multipart/alternative; boundary="000000000000ace4fa05e9307e90"
X-Spam-Score: 0.3 (/)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

--000000000000ace4fa05e9307e90
Content-Type: text/plain; charset="UTF-8"

> > I cannot reproduce on stable branch either. Only on main.
>
> Then why do you think this is a problem in the core?
>

As I said in my first message, I either misunderstand something about
autoload or it is some kind of
Emacs bug.

Note that doing emacs -Q -l /tmp/bug.el vs emacs -Q /tmp/bug.el +
eval-buffer yields different results.
I cannot possibly see how it can be anything to do with Org and I have no
clue how to approach debugging this.

Best,
Ihor

--000000000000ace4fa05e9307e90
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div dir=3D"ltr"></div><div class=3D"gmail_quote"><blockqu=
ote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px=
 solid rgb(204,204,204);padding-left:1ex">
&gt; I cannot reproduce on stable branch either. Only on main.<br>
<br>
Then why do you think this is a problem in the core?<br></blockquote><div><=
br></div><div>As I said in my first message, I either misunderstand somethi=
ng about autoload or it is some kind of</div><div>Emacs bug.=C2=A0</div><di=
v><br></div><div>Note that doing emacs -Q -l /tmp/bug.el vs emacs -Q /tmp/b=
ug.el=C2=A0+ eval-buffer yields different results.</div><div>I cannot possi=
bly see how it can be anything to do with Org and I have no clue how to app=
roach debugging this.</div><div><br></div><div>Best,</div><div>Ihor</div></=
div></div>

--000000000000ace4fa05e9307e90--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 14:04:52 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 10:04:52 2022
Received: from localhost ([127.0.0.1]:34892 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1ob0LM-0000kF-1z
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 10:04:52 -0400
Received: from eggs.gnu.org ([209.51.188.92]:42808)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1ob0LJ-0000k2-Ka
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 10:04:50 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:56632)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1ob0LE-0004S8-AN; Wed, 21 Sep 2022 10:04:44 -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=4/eC40tcCgz4OT1u6B5nQOSUGCcXtJIrclSOoMaoJVA=; b=JuQAJvxARUur
 6hyN8SFymcpJmM+DHUAYGh6O9DqOi5OAJWWJ5Kxigd6ybEkbLfmBUSvgIW02a+i9seRrBaW+ncxYR
 Q/rqEYqVNn3LS4BhdxI45w4hydV1T6V3Id0NT7qOVFKx7sSVDWiXC5iNGlkArKfouM0d4qGOl4Lcw
 2oiCVW14ih5Z2pMOF7Ju5yJuGCC0i1GcUImLtRjJ4Q8tWdaB5OP/a5RxUlnJvOvU71psEznbXeZkO
 VKImkeehEI8oxDDL9uznPvDN0jHVMNXBr8Y525JQMetqERwHjGBPvad7+Quq+E9tiFCfYYQ9Q79Pz
 D5wfSkLvbBxl0GGm549EhQ==;
Received: from [87.69.77.57] (port=4671 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1ob0LA-0005of-NB; Wed, 21 Sep 2022 10:04:42 -0400
Date: Wed, 21 Sep 2022 17:04:50 +0300
Message-Id: <8335ckvn5p.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Ihor Radchenko <yantar92@HIDDEN>
In-Reply-To: <CACnOyiifySWH8njQBSLpBoGQzdxdqS7CPC47cEkCur5YSwXkkg@HIDDEN>
 (message from Ihor Radchenko on Wed, 21 Sep 2022 21:19:26 +0800)
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <83edw4vqsq.fsf@HIDDEN>
 <CACnOyihWEN+WTA17ijKSSW8SrN=8cD16TP=U-58yq+9sJPL-mQ@HIDDEN>
 <838rmcvphe.fsf@HIDDEN>
 <CACnOyiifySWH8njQBSLpBoGQzdxdqS7CPC47cEkCur5YSwXkkg@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Ihor Radchenko <yantar92@HIDDEN>
> Date: Wed, 21 Sep 2022 21:19:26 +0800
> Cc: 57972 <at> debbugs.gnu.org
> 
>  So reproducing this requires the development version of Org?
> 
> Yes.
>  
>  I cannot reproduce with the version of Org we have on the Emacs
>  master branch.
> 
>  
> I cannot reproduce on stable branch either. Only on main.

Then why do you think this is a problem in the core?




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 13:18:46 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 09:18:46 2022
Received: from localhost ([127.0.0.1]:32974 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oazck-0007Tr-6S
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 09:18:46 -0400
Received: from mail-lf1-f54.google.com ([209.85.167.54]:43850)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <yantar92@HIDDEN>) id 1oazci-0007Te-M0
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 09:18:45 -0400
Received: by mail-lf1-f54.google.com with SMTP id o2so9139575lfc.10
 for <57972 <at> debbugs.gnu.org>; Wed, 21 Sep 2022 06:18:44 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:from:to:cc:subject:date;
 bh=uQnpzT2LidvgVidix8AluQ8gZST1tsD4T92DxoJrqvw=;
 b=RSiyy46fwVE5ZJoZ8CJveaxtvuHTnTfn86228w76dpxyPvJstsVEXj+1YrlOHshSx8
 z17sLol9AjokHtNViOPAJQ094rR9pPSuqTVFh9wotHEv04XuowO6w7f5pREosVJeu6XC
 tBZfGS0oC8Rg2Afip9Jrtiol4SwNaa2FptcTBW/eSDsxPrDoWg10WWOzcGB1fHSBq7+Q
 SKq2EoNUB0tXHKYrRmR2UibtNwt9A08D0XRrcHVvfBDS0tQJ/4OPkUKH+ye4kgg4u8sh
 Zm76HjllcMdbfJydV+TDfzG6wpyS5Xd9RhdUtv0/0Gl1N2FIWdlkhigjl+/A6jyTiojs
 uqSg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:x-gm-message-state:from:to:cc:subject:date;
 bh=uQnpzT2LidvgVidix8AluQ8gZST1tsD4T92DxoJrqvw=;
 b=am/E6VKUGd0T6o3r3NSJzAggu7bH8ULdVn76G/C6ZKLgKtJPMa69F8i89vGTAx0YlU
 3r62Afs8ks/tyfd4zdCxJ+sjIQnALoEpbRtX3pPoupSVLV8uw+MapH852N00VEeHpbZb
 sr0IGH7xMtYAYFP0cwCL09rW66V5EGzZ/7ubcsTlNdI2l+kaYlOCJhzyYjrjwOOjp7Wr
 B4MZEE0Kkc+KOdZA+lZSGjHyaPomnJuBH0oWaVfMA/s47FxsW2Ziw3ATCacjBTcf3AqS
 16B6SLLp3pOzIwwbAKyVVMT2L7nhbv9kQt8CklTz0Mcwtfmp7xx1LTa+/APzkYXTHDYg
 k+Wg==
X-Gm-Message-State: ACrzQf3a2xKCHKlhziq72qgQgkgUQQ4Ff1RG7pihpIkICjriy4scVJav
 RjKmkW82KMqYDC3cuR7kL5FsAf2SCb7nx3iJlowgs5oZ
X-Google-Smtp-Source: AMsMyM7PJE9rY8ZU+rNmRmPkFADiXMLVyPytL9Z8Psnx8rVCmLIVQ4FOzvadbiqukC+G49mTwH7c0y5lpZGa1zxffgo=
X-Received: by 2002:a05:6512:138d:b0:499:cf11:ca77 with SMTP id
 p13-20020a056512138d00b00499cf11ca77mr9766062lfa.140.1663766318421; Wed, 21
 Sep 2022 06:18:38 -0700 (PDT)
MIME-Version: 1.0
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <83edw4vqsq.fsf@HIDDEN>
 <CACnOyihWEN+WTA17ijKSSW8SrN=8cD16TP=U-58yq+9sJPL-mQ@HIDDEN>
 <838rmcvphe.fsf@HIDDEN>
In-Reply-To: <838rmcvphe.fsf@HIDDEN>
From: Ihor Radchenko <yantar92@HIDDEN>
Date: Wed, 21 Sep 2022 21:19:26 +0800
Message-ID: <CACnOyiifySWH8njQBSLpBoGQzdxdqS7CPC47cEkCur5YSwXkkg@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
To: Eli Zaretskii <eliz@HIDDEN>
Content-Type: multipart/alternative; boundary="000000000000661ae005e92fc884"
X-Spam-Score: 0.3 (/)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

--000000000000661ae005e92fc884
Content-Type: text/plain; charset="UTF-8"

>
> So reproducing this requires the development version of Org?
>

Yes.


> I cannot reproduce with the version of Org we have on the Emacs
> master branch.
>

I cannot reproduce on stable branch either. Only on main.

Best,
Ihor

--000000000000661ae005e92fc884
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_quote"><blockquote class=3D"gmail_quot=
e" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204)=
;padding-left:1ex">
So reproducing this requires the development version of Org?<br></blockquot=
e><div><br></div><div>Yes.</div><div>=C2=A0</div><blockquote class=3D"gmail=
_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204=
,204);padding-left:1ex">
I cannot reproduce with the version of Org we have on the Emacs<br>
master branch.<br></blockquote><div>=C2=A0</div><div>I cannot reproduce on =
stable branch either. Only on main.</div><div><br></div><div></div><div>Bes=
t,<br></div><div>Ihor</div></div></div>

--000000000000661ae005e92fc884--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 13:14:42 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 09:14:42 2022
Received: from localhost ([127.0.0.1]:32949 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oazYn-0007Lx-NE
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 09:14:41 -0400
Received: from eggs.gnu.org ([209.51.188.92]:59816)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1oazYi-0007Lg-4P
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 09:14:39 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:38850)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1oazYc-0002P5-Mu; Wed, 21 Sep 2022 09:14:30 -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=CWX/0D3lyhQOBID9p9qrRemEvK6oe6lXQVH0xXZ38s8=; b=Erk1yJ18ian2
 ogFAdhbJPrLCuV8hzDuYCkFcfnYO9C4aWGltYNtRKKlX61qXjEjos+JUBUx5WpITf2r0c1Kkk6D2o
 StwH46y8qTnFOp+GqxNgSGvCgsXAGSkdkW8jBPizVhIdyFQgv2Lw9mWun5snvOxhvJuxtJUH/szl+
 1yT0WYMqqyEhuHoOUX0H7J3CYg/INwMu/ddmh+OvNwhhjkV8N9AwuIsyyvwirUE/M+2gOqSq6ovuA
 FdR5yv3Bgzcq6jw+F/w5JmnBwbKlh5+oHXSgpuxT9BL5m2rRafw1jkTIejbU+aDsN4SWSFrQkD8hR
 Of26c6KyXVIt4nmAOpwuVA==;
Received: from [87.69.77.57] (port=1585 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1oazYb-0004mS-Vv; Wed, 21 Sep 2022 09:14:30 -0400
Date: Wed, 21 Sep 2022 16:14:37 +0300
Message-Id: <838rmcvphe.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Ihor Radchenko <yantar92@HIDDEN>
In-Reply-To: <CACnOyihWEN+WTA17ijKSSW8SrN=8cD16TP=U-58yq+9sJPL-mQ@HIDDEN>
 (message from Ihor Radchenko on Wed, 21 Sep 2022 21:00:08 +0800)
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <83edw4vqsq.fsf@HIDDEN>
 <CACnOyihWEN+WTA17ijKSSW8SrN=8cD16TP=U-58yq+9sJPL-mQ@HIDDEN>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Ihor Radchenko <yantar92@HIDDEN>
> Date: Wed, 21 Sep 2022 21:00:08 +0800
> Cc: 57972 <at> debbugs.gnu.org
> 
>  Alternatively, a complete recipe (without referring to directories
>  that I definitely don't have here) to reproduce the problem could
>  answer all those questions succinctly and efficiently.
> 
> Here it is
> 1. cd /tmp
> 2. git clone git://git.sv.gnu.org/emacs/org-mode.git

So reproducing this requires the development version of Org?

> 3. cd org-mode
> 4. make autoloads
> 5. Create /tmp/bug.el with the following contents:
> -----
> (add-to-list 'load-path "/tmp/org-mode/lisp")
> (require 'org)
> -----
> 6. Create /tmp/bug.org with the following contents:
> -----
> * TODO start clock on this test item
> -----
> 7. emacs -Q /tmp/bug.el
> 8. M-x eval-buffer
> 9. C-x C-f /tmp/bug.org
> 10. Observe error in echo area

I cannot reproduce with the version of Org we have on the Emacs
master branch.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 12:59:30 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 08:59:29 2022
Received: from localhost ([127.0.0.1]:32901 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oazK5-0006vd-Ht
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:59:29 -0400
Received: from mail-lf1-f48.google.com ([209.85.167.48]:35523)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <yantar92@HIDDEN>) id 1oazK2-0006vP-Ue
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:59:27 -0400
Received: by mail-lf1-f48.google.com with SMTP id z25so9111180lfr.2
 for <57972 <at> debbugs.gnu.org>; Wed, 21 Sep 2022 05:59:26 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:from:to:cc:subject:date;
 bh=qCDKgC8dZam6ZwjarNi+YjhtajfDxRC47esJLwaKN2w=;
 b=mtPl84/U4qL4o34Z+VbpZUR8Boa1MFHnRWtxYw/rFE5SfDlgJpsKqhTO61nmu65E+j
 oF/rJmHpmWEZExV9dAPt34g2g8ryEhmgmFWqmWcX1+bE3PQ8sRxBlH8o27qaGSpKgU7b
 FZFqUjboS77VsaeciJ/ZrjNuwxEiqd9fViDsEnQf6ceHmSqgmp+/wL78oODTgU8h8WxT
 OYKDg0oUNxwnQTwwCu1k7DE/mXgtIDXNii0BDFrPhRZSeMKRiUwYP1Pnwkd7MEVj5j60
 Soft1iZ269MVzV/pRJil2fI7QS035r138hwmeP9nC3JUS3BJwGxHJqFjf8wkq4EJ6/sG
 hFzQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:x-gm-message-state:from:to:cc:subject:date;
 bh=qCDKgC8dZam6ZwjarNi+YjhtajfDxRC47esJLwaKN2w=;
 b=bdYTbHDeUdaM+yT8lAv25ODVkpcO49AznGW2M+o4e/CNsTDxEB1cb2fweoy8djIKGM
 LkjIbdFnbjKbp+0WRMpZYqgQGGdWg6MBZNEfaEZR1JwKI5IA0anosmbERS6uGQ/pN9b7
 ykUic1PukcY8SjLkGD3r4M7jBZojLnWBzVnpRQAAplfihmRynwB9YWqh74oeN/jsnAa1
 YbdlyC9xSXEswA7rTVmXhhDmBs17v+SBl2Gfzn2uB0FNg7AMD39Wx7xd8sDEqNYCnI/w
 eM6t4l8DhL9Rwehdiiw66pYWHEVaTQB+jOhOM/TA0BUUquKtjkXak9+Z9HR82f2GEhQX
 OIeg==
X-Gm-Message-State: ACrzQf1lgqns6GeUwFgGKRDC6FxWpEdJTC1q8UBH2QkF3mwN9FfHAIaD
 DL/u1JWwdtdiGOgP7+AmPmcK53pWYWqxsCFCByXI98KnrVzY3g==
X-Google-Smtp-Source: AMsMyM7twPjYQ8j6qhrKA5ORDiqFAOYUU/gFOTi2Icjhe9HYN8liZRjOQRUul8+F7TSJIhE/OJUDCDyjbaqxTaoXikQ=
X-Received: by 2002:ac2:5bd2:0:b0:498:909:9c81 with SMTP id
 u18-20020ac25bd2000000b0049809099c81mr9484636lfn.120.1663765160829; Wed, 21
 Sep 2022 05:59:20 -0700 (PDT)
MIME-Version: 1.0
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <83edw4vqsq.fsf@HIDDEN>
In-Reply-To: <83edw4vqsq.fsf@HIDDEN>
From: Ihor Radchenko <yantar92@HIDDEN>
Date: Wed, 21 Sep 2022 21:00:08 +0800
Message-ID: <CACnOyihWEN+WTA17ijKSSW8SrN=8cD16TP=U-58yq+9sJPL-mQ@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
To: Eli Zaretskii <eliz@HIDDEN>
Content-Type: multipart/alternative; boundary="00000000000066a94e05e92f836b"
X-Spam-Score: 0.3 (/)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

--00000000000066a94e05e92f836b
Content-Type: text/plain; charset="UTF-8"

>
> Alternatively, a complete recipe (without referring to directories
> that I definitely don't have here) to reproduce the problem could
> answer all those questions succinctly and efficiently.
>

Here it is
1. cd /tmp
2. git clone git://git.sv.gnu.org/emacs/org-mode.git
3. cd org-mode
4. make autoloads
5. Create /tmp/bug.el with the following contents:
-----
(add-to-list 'load-path "/tmp/org-mode/lisp")
(require 'org)
-----
6. Create /tmp/bug.org with the following contents:
-----
* TODO start clock on this test item
-----
7. emacs -Q /tmp/bug.el
8. M-x eval-buffer
9. C-x C-f /tmp/bug.org
10. Observe error in echo area

Note that doing emacs -Q -l /tmp/bug.el in step 7 does _not_ trigger the
error.

Best,
Ihor

--00000000000066a94e05e92f836b
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_quote"><blockquote class=3D"gmail_quot=
e" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204)=
;padding-left:1ex">
Alternatively, a complete recipe (without referring to directories<br>
that I definitely don&#39;t have here) to reproduce the problem could<br>
answer all those questions succinctly and efficiently.<br></blockquote><div=
><br></div><div>Here it is</div><div>1. cd /tmp</div><div>2.=C2=A0<span sty=
le=3D"background-color:rgb(230,230,230);color:rgb(50,50,50);font-family:&qu=
ot;Droid Sans Mono&quot;;font-size:14.688px">git clone git://<a href=3D"htt=
p://git.sv.gnu.org/emacs/org-mode.git">git.sv.gnu.org/emacs/org-mode.git</a=
></span></div><div>3. cd org-mode</div><div>4. make autoloads</div><div>5. =
Create /tmp/bug.el with the following contents:</div><div>-----</div><div>(=
add-to-list &#39;load-path &quot;/tmp/org-mode/lisp&quot;)<br>(require &#39=
;org)<br></div><div>-----</div><div>6. Create /tmp/<a href=3D"http://bug.or=
g">bug.org</a> with the following contents:</div><div>-----</div><div>* TOD=
O start clock on this test item<br></div><div>-----</div><div>7. emacs -Q /=
tmp/bug.el</div><div>8. M-x eval-buffer</div><div>9. C-x C-f /tmp/<a href=
=3D"http://bug.org">bug.org</a></div><div>10. Observe error in echo area</d=
iv><div><br></div><div>Note that doing emacs -Q -l /tmp/bug.el in step 7 do=
es _not_ trigger the error.</div><div><br></div><div>Best,</div><div>Ihor</=
div></div></div>

--00000000000066a94e05e92f836b--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 12:46:25 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 08:46:25 2022
Received: from localhost ([127.0.0.1]:32888 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oaz7R-0006bI-Gw
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:46:25 -0400
Received: from eggs.gnu.org ([209.51.188.92]:51702)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1oaz7P-0006b1-V8
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:46:24 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:47612)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1oaz7K-0005sD-6H; Wed, 21 Sep 2022 08:46:18 -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=R+BxwAY/aIrCHPJ96Ri1kpj+iNr19EdsgS2879k9NnE=; b=QvM959m8iVt/
 HIXT/w9vHbnTAlLZF1xLbSWmRw+RHEVtcIjE77NTmrg+ZLyIhktrZcggDljJcqSxi7q8/jrRkBSa/
 tIMz5IvUmj1oUzfk5/luTOG+KEuJuMoG/bSRV+UeDpwJtQsg3iPJXCGRTdN9CE9M1evItfsmk/6aU
 HUSmCdupO12kRSO3VrLwt7q8QnUnMYhaEIWENcKwey4sbHVUVhoK7qCsRFV77SEugFBy0LBOWwtF8
 USE2xfSxoIHqXHSNdgP+UYc3+AQ5pAJE6U/mqxKJZtOEH7yXimq2H2EKLwOhVv98jIrDT5OxSjhfE
 DB0bXidAhWx7fqZrHYe1XQ==;
Received: from [87.69.77.57] (port=3805 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1oaz76-0003zG-T0; Wed, 21 Sep 2022 08:46:17 -0400
Date: Wed, 21 Sep 2022 15:46:13 +0300
Message-Id: <83edw4vqsq.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Ihor Radchenko <yantar92@HIDDEN>
In-Reply-To: <8735clx8cl.fsf@localhost> (message from Ihor Radchenko on Wed,
 21 Sep 2022 19:41:46 +0800)
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost>
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Ihor Radchenko <yantar92@HIDDEN>
> Cc: 57972 <at> debbugs.gnu.org
> Date: Wed, 21 Sep 2022 19:41:46 +0800
> 
> Eli Zaretskii <eliz@HIDDEN> writes:
> 
> > Would it be possible to have more info about the details?  Like what
> > are org-element-cache-reset and org-element-citation-prefix-re, and
> > how do they enter the picture in the above scenario?
> 
> Let's forget about org-element-citation-prefix-re for now.
> 
> org-element-cache-reset is an autoloaded function defined inside
> org-element.el
> 
> Major mode body `org-mode' from org.el is calling
> `org-element-cache-reset' as part of Org mode loading.
> 
> org.el does not contain (require 'org-element).
> Instead, it is assumed that `org-element-cache-reset' is autoloaded by
> Emacs.

org-element-cache-reset's autoload form is in org-loaddefs.el.

The error message reported by the OP, viz.:

  File mode specification error: (void-function org-element-cache-reset)

comes from normal-mode when it calls set-auto-mode.  So something goes
wrong there, perhaps because org-element-cache-reset is called before
org.el loads org-loaddefs.el with this snippet:

  (or (eq this-command 'eval-buffer)
      (condition-case nil
	  (load (concat (file-name-directory load-file-name)
			"org-loaddefs")
		nil t nil t)
	(error
	 (message "WARNING: No org-loaddefs.el file could be found from where org.el is loaded.")
	 (sit-for 3)
	 (message "You need to run \"make\" or \"make autoloads\" from Org lisp directory")
	 (sit-for 3))))

I don't know what goes wrong, because I cannot reproduce the problem
here, if I just visit a (non-existent) foo.org.  After visiting the
file, (fboundp 'org-element-cache-reset) yields t.  So I have questions:

  . does this happen in "emacs -Q"?
  . does org-loaddefs.el exist on load-path, and is it being loaded by
    org.el?
  . could it be that user customizations somehow define file-local
    variables or directory-local variables or something else that
    attempts to use org-element-cache-reset too early?

Alternatively, a complete recipe (without referring to directories
that I definitely don't have here) to reproduce the problem could
answer all those questions succinctly and efficiently.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 12:31:32 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 08:31:32 2022
Received: from localhost ([127.0.0.1]:32852 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oayt2-0006DY-A9
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:31:32 -0400
Received: from mail-lj1-f177.google.com ([209.85.208.177]:37865)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <yantar92@HIDDEN>) id 1oayt0-0006DK-3v
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:31:30 -0400
Received: by mail-lj1-f177.google.com with SMTP id j24so6303517lja.4
 for <57972 <at> debbugs.gnu.org>; Wed, 21 Sep 2022 05:31:30 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:from:to:cc:subject:date;
 bh=erf1PsXGsNpRfEIl3DPXnp3BZC9pGDHlJPZQz3jn/cY=;
 b=DygK+MPe+x6SNHKznRUGUNPFu3oRC0eyNA6UwKJnEAVHe7x3K5ASgwLX4gk3fJ/XLz
 53StBhcZpRStmoRI9WzTTu3UvmV8Fb3Okv2CAfMyaNkJ0jHzqXnCfzX1K4K6kFsGVpi6
 1dFxsdnaObogQDSdxdUNmzmtHrK7GQ262wqoPqJFl0kV+CW0Ilg0olyq2MXM4+L0uxOb
 SYk0RSfwcMwPBI2rfhURKu2iWO+YEFtKF1MDQjZ1zXNtFy3Dg12WsaKB6mYoQnPoc33H
 EsspJrUtQXJ5pCuyLnnU8kd+nvPAL1yxpGKJR03X1WGGbI/STQtOAPY1ZAJk4nxhLi3Q
 f+DA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=cc:to:subject:message-id:date:from:in-reply-to:references
 :mime-version:x-gm-message-state:from:to:cc:subject:date;
 bh=erf1PsXGsNpRfEIl3DPXnp3BZC9pGDHlJPZQz3jn/cY=;
 b=VxW2MofRJ2kkwFElxjSJwvL3NuYmg7WrUrjMFdhLI0x0o6q7P8/HzaGvG48Tpq07dH
 VksaiGnwa02+Epf3B0qTdXHOBSSAJym6M6FGcQ01YaPGRxlS7VN1PPrb42X9OhYfKYg4
 Wbo91J/nYSsKBisQYPFDBdo95rAiVg1tcMsIYKJmSgZxhS6iua+pxwIBj5aMpzx1ifj8
 Z8ieUmu6ZSk6tSCHVBVlWXfZnY1OmTAOIZYQ/KmaDRNMDOZxT5mrgRTNVBZ9QbD6lF+y
 npFKeKoCN0dr81S32tIqSGnwsYHNeYI7rJIONIs6ENxBbF1TYIX9KlqR9TeNUHFbn/+J
 rNyw==
X-Gm-Message-State: ACrzQf3+SpCTCVLnMIBy5t9bxQ282gdayfJMHHHxz7CRYOBX3aIKfsS6
 0viNV2VSNeoaKMZFJH1hlZB52iSKPK1n1mDx81A=
X-Google-Smtp-Source: AMsMyM5gzzRffdBTPgmaXiA/VC16pOxB2tgAUANMA+1eD5nXYyP3U2SB1pddzXGZw63VOK0mhAVxTloS0ecE1jTb464=
X-Received: by 2002:a2e:541c:0:b0:26c:16d6:6872 with SMTP id
 i28-20020a2e541c000000b0026c16d66872mr8595237ljb.220.1663763482667; Wed, 21
 Sep 2022 05:31:22 -0700 (PDT)
MIME-Version: 1.0
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <875yhh6iwz.fsf@HIDDEN>
 <87zgetvsj7.fsf@localhost> <87k05w6hw3.fsf@HIDDEN>
In-Reply-To: <87k05w6hw3.fsf@HIDDEN>
From: Ihor Radchenko <yantar92@HIDDEN>
Date: Wed, 21 Sep 2022 20:32:10 +0800
Message-ID: <CACnOyigm7bLGdMoO1riPYq5166XF4FcOd2pOz_=1KKZ2iiX_wA@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
To: Lars Ingebrigtsen <larsi@HIDDEN>
Content-Type: multipart/alternative; boundary="0000000000005ff1db05e92f1f73"
X-Spam-Score: 0.3 (/)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

--0000000000005ff1db05e92f1f73
Content-Type: text/plain; charset="UTF-8"

>
> > You have some confusing stuff in org.el -- you have a
>
> > (declare-function org-element-cache-reset "org-element" (&optional all))
>
> > to suppress warnings in org.el about that function, but
> > org-element-cache-reset should be in org-loaddefs, which org.el loads
> > already, so it should be unnecessary.


The declare statement is there for a single reason---to pacify native-comp
warnings.

 If it isn't unnecessary, then something else is going wrong somewhere,

> I'd have thought?  But I haven't tried debugging further.
>

I removed the declare statement. The bug persists. Also,
org-element-cache-reset is present in org-loaddefs.el

Best,
Ihor

--0000000000005ff1db05e92f1f73
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_quote"><blockquote class=3D"gmail_quot=
e" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204)=
;padding-left:1ex">&gt; You have some confusing stuff in org.el -- you have=
 a<br>
<br>&gt; (declare-function org-element-cache-reset &quot;org-element&quot; =
(&amp;optional all))<br>
<br>&gt; to suppress warnings in org.el about that function, but<br>&gt; or=
g-element-cache-reset should be in org-loaddefs, which org.el loads<br>&gt;=
 already, so it should be unnecessary.</blockquote><div><br></div><div>The =
declare statement is there for a single reason---to pacify native-comp warn=
ings.</div><div>=C2=A0=C2=A0<br></div><div>=C2=A0If it isn&#39;t unnecessar=
y, then something else is going wrong somewhere,</div><blockquote class=3D"=
gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(20=
4,204,204);padding-left:1ex">
I&#39;d have thought?=C2=A0 But I haven&#39;t tried debugging further.<br><=
/blockquote><div><br></div><div>I removed the declare statement. The bug pe=
rsists. Also, org-element-cache-reset is present in org-loaddefs.el</div><d=
iv><br></div><div>Best,</div><div>Ihor=C2=A0</div></div></div>

--0000000000005ff1db05e92f1f73--




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 12:18:06 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 08:18:06 2022
Received: from localhost ([127.0.0.1]:32826 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oayg2-0005rS-50
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:18:06 -0400
Received: from quimby.gnus.org ([95.216.78.240]:37942)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1oayft-0005ql-SP
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:18:05 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:Date:References:
 In-Reply-To:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=fDU7VpsDhnCMF6YMLm4EiwDSEpXhjHIZ2EhtNUZXwpo=; b=kuSNGLWA+e+T1LYM+c+G/R7H+p
 vR3kqm691qaBv5bx7qcZo1zCF/pK00IrCM9yrLI/5jYrcvlA3MnlPfUX0J7QZKPAhnWs1FkZt7uWP
 i2YmYqE7tVEfJMlePDKDk1J1DGlxWHWttNWuzZ46QjPXsSZfcm1fhzIsA6fpVgQWaveI=;
Received: from [84.212.220.105] (helo=joga)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1oayfk-0004zp-SM; Wed, 21 Sep 2022 14:17:51 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Ihor Radchenko <yantar92@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
In-Reply-To: <87zgetvsj7.fsf@localhost> (Ihor Radchenko's message of "Wed, 21
 Sep 2022 20:08:44 +0800")
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <875yhh6iwz.fsf@HIDDEN>
 <87zgetvsj7.fsf@localhost>
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj
 SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAADFBMVEWkRUzBsbE5Jiv/
 //9EG+24AAAAAWJLR0QDEQxM8gAAAAd0SU1FB+YJFQs7EqVA5nIAAAGjSURBVCjPPZIxa+NAEIVH
 IgrBlTCWCamSFIe8v2IJOIUrWewITlWK5Ej0K4SwDuHqcpxNksoRkVm9X3mzkslW+82w7808lqYN
 Lq8vJ7+r+FBSut1O2zccYduSzNXHvH1/OFaLdkP+G+ZoblsAByLywwsi/I2pJPKIdJD3MxpPqGfo
 H4crU7QsYL9IE635LEoBy1IViFiUOtYCHge5QD8AMeffHQEjwMtE7hEzrwsrpaEhp+hMZMgfwWzM
 PghPHa6f9gHrE3TP97WAE1jw02KAQKA9MM5ZwGO+24LT0ml7zlS9ZrsT8AqvTmV0zeFkdprCtXnR
 q4ifYRMy+UZdmGGnhMK0RsOcQeEPUWaxcwAcic56Jc//KbQSoqd6aezc6g5ks6wWsGJUyCR+54IQ
 05eAJxgh5J8sJnU6whBPlygnwEuWam8UIoGAV19xw/iciJpXx2w+9sjgwCU4R60GuHUaNnc+RL8q
 AZnnWgR0al3CWzcN6ysbcHYIaSmmeopPgzoRkM456pUNJAGiGf2wdzYmvyGS33ETwaqyssNP6Aso
 1VZQ/wGiGsRQg+CqXwAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wOS0yMVQxMTo1OToxOCswMDow
 MLRFwnsAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDktMjFUMTE6NTk6MTgrMDA6MDDFGHrHAAAA
 AElFTkSuQmCC
X-Now-Playing: The Waitresses's _Wasn't Tomorrow Wonderful?_: "Wasn't
 Tomorrow Wonderful?"
Date: Wed, 21 Sep 2022 14:17:48 +0200
Message-ID: <87k05w6hw3.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Ihor Radchenko <yantar92@HIDDEN> writes: >> I'm not at
 all sure I understand myself. A backtrace here would be >> helpful. > >
 Debugger
 entered--entering a function: > * message("File mode specification error:
 %s" (void-function > org-elemen [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Ihor Radchenko <yantar92@HIDDEN> writes:

>> I'm not at all sure I understand myself.  A backtrace here would be
>> helpful.
>
> Debugger entered--entering a function:
> * message("File mode specification error: %s" (void-function
> org-element-cache-reset))
>   normal-mode(t)
>   after-find-file(nil t)
>   find-file-noselect-1(#<buffer bug.org> "/tmp/bug.org" nil nil
> "/tmp/bug.org" (127741036 26))
>   find-file-noselect("/tmp/bug.org" nil nil t)
>   find-file("/tmp/bug.org" t)
>   funcall-interactively(find-file "/tmp/bug.org" t)
>   command-execute(find-file)
>
> I generated the backtrace using M-x debug-on-entry org-mode and opening
> bug.org. The backtrace appears at the moment I try to step through
> org-element-cache-reset call inside org-mode.

You have some confusing stuff in org.el -- you have a

(declare-function org-element-cache-reset "org-element" (&optional all))

to suppress warnings in org.el about that function, but
org-element-cache-reset should be in org-loaddefs, which org.el loads
already, so it should be unnecessary.

If it isn't unnecessary, then something else is going wrong somewhere,
I'd have thought?  But I haven't tried debugging further.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 12:08:06 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 08:08:06 2022
Received: from localhost ([127.0.0.1]:32793 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oayWI-0005ae-AP
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:08:06 -0400
Received: from mail-pj1-f44.google.com ([209.85.216.44]:44610)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <yantar92@HIDDEN>) id 1oayWD-0005a9-RN
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 08:08:01 -0400
Received: by mail-pj1-f44.google.com with SMTP id
 i15-20020a17090a4b8f00b0020073b4ac27so5588750pjh.3
 for <57972 <at> debbugs.gnu.org>; Wed, 21 Sep 2022 05:07:57 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=mime-version:message-id:date:references:in-reply-to:subject:cc:to
 :from:from:to:cc:subject:date;
 bh=VWJXIXMEJLiOQVKC4Sk30vbgkQvBpfKAMZrrDDUnhto=;
 b=IxR+mZ0OFp3FmUtt2MjkX1yJI9l/0UfABfTdtw3IWZR5K6j94BVgKLmq7cocAXnahr
 33yAOM0pheXSr45PeqGbNl8nKhc1Hoze87A8URtGGjdkyi7NPCOQPP3L2vEUSY4qlwfS
 QTqelcr3zm19EJaqVfwkrEM607vY90VfOGo9o24SxPOTTb0N6aQKCG17D8bUsqcOCobc
 /IL1dO7k3Dnik7nJT06FPBB37pcgUKSfl/fnZhA1DHGshnSlXbUClQId1WmyMO7Io+v+
 n9bwLnnBFU5L1oM6hNmTLdRtbBaCJDTQjx92EP1Cws0GWkUG2BnXNE1ckT6oya/bTZm2
 qHZA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=mime-version:message-id:date:references:in-reply-to:subject:cc:to
 :from:x-gm-message-state:from:to:cc:subject:date;
 bh=VWJXIXMEJLiOQVKC4Sk30vbgkQvBpfKAMZrrDDUnhto=;
 b=g0fUlJZXrVzZlzaNhp7U3e5NB1z+DRVfFwptk57ijKxf2gz3DHdoLdS7qj9kntCUfB
 NWGItu1KOe5+F5cAGrp+mG9rWRKuhfiEPPAQo8whh3zQ8GE+XvxmGLurQW2AksDpbMDn
 m1aW8kgeVS1kWyCMjBrp0MKI8Sia9cpaajNbTVpGDHRxBdRgHxZNGb3F85B014p5qdmP
 Z8Aaoh88YwjtYmin7xT8105U5xS+Iw2f0Y54MGG/Pg7HtuZUkfq2jLnRIu16g0DyO8ug
 675forT5t/YFiyKtqjvqpT7w0hFJHT+UbpHAhEIQwkK8wQnchHzdSZftILaWpasoD0KT
 55ig==
X-Gm-Message-State: ACrzQf3gWlz+ua9/44ZaY1AcazhA8pWcJAdyNgqz71QwA1mEI9cTLgAn
 I89OOC8jGHEXdxo/Glj9MhU=
X-Google-Smtp-Source: AMsMyM6VTdo0jeadp8q5KjMn7H5sGky/n+NKP3i/GbL0vAFtyDOdEfEVnDCgR+jSxaRlTonniB00mQ==
X-Received: by 2002:a17:902:c944:b0:178:4568:9f99 with SMTP id
 i4-20020a170902c94400b0017845689f99mr4540483pla.98.1663762072050; 
 Wed, 21 Sep 2022 05:07:52 -0700 (PDT)
Received: from localhost ([2409:8a70:2b5:ad00:8ec6:81ff:fe70:339d])
 by smtp.gmail.com with ESMTPSA id
 cx1-20020a17090afd8100b002036006d65bsm1694053pjb.39.2022.09.21.05.07.49
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Wed, 21 Sep 2022 05:07:50 -0700 (PDT)
From: Ihor Radchenko <yantar92@HIDDEN>
To: Lars Ingebrigtsen <larsi@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
In-Reply-To: <875yhh6iwz.fsf@HIDDEN>
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost> <875yhh6iwz.fsf@HIDDEN>
Date: Wed, 21 Sep 2022 20:08:44 +0800
Message-ID: <87zgetvsj7.fsf@localhost>
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.3 (/)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.7 (/)

Lars Ingebrigtsen <larsi@HIDDEN> writes:

> I'm not at all sure I understand myself.  A backtrace here would be
> helpful.

Debugger entered--entering a function:
* message("File mode specification error: %s" (void-function org-element-cache-reset))
  normal-mode(t)
  after-find-file(nil t)
  find-file-noselect-1(#<buffer bug.org> "/tmp/bug.org" nil nil "/tmp/bug.org" (127741036 26))
  find-file-noselect("/tmp/bug.org" nil nil t)
  find-file("/tmp/bug.org" t)
  funcall-interactively(find-file "/tmp/bug.org" t)
  command-execute(find-file)

I generated the backtrace using M-x debug-on-entry org-mode and opening
bug.org. The backtrace appears at the moment I try to step through
org-element-cache-reset call inside org-mode.

-- 
Ihor Radchenko,
Org mode contributor,
Learn more about Org mode at https://orgmode.org/.
Support Org development at https://liberapay.com/org-mode,
or support my work at https://liberapay.com/yantar92




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 11:55:50 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 07:55:50 2022
Received: from localhost ([127.0.0.1]:60997 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oayKU-00034r-D1
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 07:55:50 -0400
Received: from quimby.gnus.org ([95.216.78.240]:37220)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1oayKS-00034b-Po
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 07:55:49 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org;
 s=20200322; h=Content-Type:MIME-Version:Message-ID:Date:References:
 In-Reply-To:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:
 Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender:
 Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:
 List-Subscribe:List-Post:List-Owner:List-Archive;
 bh=YBVZFRTgyIQ/WmXVBmut4vNmGNmEKpTMNuup/JCzAIE=; b=XQ+JmBx7cXl8cAqYqzU4pCKD5W
 m6+Pzx8xoS+XeZl93T3/9I0fsAA/a8ClfXT+R6ZOHTDcCVppRrndFsy/IqJWuzpgtNgQl5aPyxZK1
 WHsQuKCm9prnqqv8ZvMZjNV4WzwI3aH0TYESqKQefhq/Jl26Srz1bSqDLve4M+rs0zoI=;
Received: from [84.212.220.105] (helo=joga)
 by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.92) (envelope-from <larsi@HIDDEN>)
 id 1oayKK-0004jn-SN; Wed, 21 Sep 2022 13:55:42 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Ihor Radchenko <yantar92@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
In-Reply-To: <8735clx8cl.fsf@localhost> (Ihor Radchenko's message of "Wed, 21
 Sep 2022 19:41:46 +0800")
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
 <8735clx8cl.fsf@localhost>
X-Now-Playing: Niki Mono's _Contradictions are a Luxury_: "In A Rush"
Date: Wed, 21 Sep 2022 13:55:40 +0200
Message-ID: <875yhh6iwz.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 @@CONTACT_ADDRESS@@ for details.
 Content preview:  Ihor Radchenko <yantar92@HIDDEN> writes: > Let's forget
 about org-element-citation-prefix-re for now. > > org-element-cache-reset
 is an autoloaded function defined inside > org-element.el > > Major mode
 body `org-mode' from org.el is calling [...] 
 Content analysis details:   (-2.9 points, 5.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 -1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
 -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%
 [score: 0.0000]
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org, Eli Zaretskii <eliz@HIDDEN>
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

Ihor Radchenko <yantar92@HIDDEN> writes:

> Let's forget about org-element-citation-prefix-re for now.
>
> org-element-cache-reset is an autoloaded function defined inside
> org-element.el
>
> Major mode body `org-mode' from org.el is calling
> `org-element-cache-reset' as part of Org mode loading.
>
> org.el does not contain (require 'org-element).
> Instead, it is assumed that `org-element-cache-reset' is autoloaded by
> Emacs.
>
> Let me know if something is not clear or if you need more detailed
> steps.

I'm not at all sure I understand myself.  A backtrace here would be
helpful.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 11:41:03 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 07:41:03 2022
Received: from localhost ([127.0.0.1]:60930 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oay6A-0000Qc-M2
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 07:41:02 -0400
Received: from mail-pf1-f175.google.com ([209.85.210.175]:36479)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <yantar92@HIDDEN>) id 1oay68-0000Ps-Fg
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 07:41:00 -0400
Received: by mail-pf1-f175.google.com with SMTP id y136so5652430pfb.3
 for <57972 <at> debbugs.gnu.org>; Wed, 21 Sep 2022 04:41:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=mime-version:message-id:date:references:in-reply-to:subject:cc:to
 :from:from:to:cc:subject:date;
 bh=MOm84idHgpxRKB7i7fGPlk5Uuq1HXdegOnNay74fB/4=;
 b=kJ8pHbGKuoht+UGeWsgpv8N2dVRsodxhHJnC0rcglf7UnRyN401qxAGuuQ/layt9lh
 q78mfT4uakDO4PcaJY3d5FIaFfJMWytk/IJnwv77+t+L0FFZmQIDFhNxoSaZ+FhWK7I4
 oot+LvDC0V20Mxc0jwEGbo1GM197BbqiGPdWBqve7KQFJ1cJBCQsqTa2FenaxysIjxjc
 LuogqZLmRlY6VnPAM8bMPnAoWq+V05t+5x0qrTfq9Ojk9ZpzE9JvxaRPHCGGr54HS7FF
 tLe/vLRPuyf2jIMdYxxbacNh9V3GaaTAMsDn+7V/mnjd/tI2tpq54bQfrExcTysvksbQ
 JiOA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=mime-version:message-id:date:references:in-reply-to:subject:cc:to
 :from:x-gm-message-state:from:to:cc:subject:date;
 bh=MOm84idHgpxRKB7i7fGPlk5Uuq1HXdegOnNay74fB/4=;
 b=N/nz+dk73wERATn3vFSdnB9yZj7BrE1+WOYOwnQ938WAwZ9PVDVLHT1SK6J+1juCL7
 woKBfNeorBQ+0pk6zwkWpZXLBnAi81f8+nhR7oe7xrq88woGDRN71weDO65UMA+bvzZA
 MCBPh0S7QeFC8bebdXWRQYwA+nB/aqizJWzHztuFnoKXX3gN54r4AX+MDF6lgdCqFjGe
 d91l0GTxqssf2PF1CVhVPkWgTGfL2LVI2jw2aQEfwjQ5WYWrGdkNSTFS0eQMHB9LRP1Z
 rBGKCx7u5QxA38eMxi0yeiR618qoMsm+M9ycE8r0i6ehUtPM7zfcd8MBTBjUeAsp5gxn
 +Zcg==
X-Gm-Message-State: ACrzQf0mSG1T1vlStSbhIjdtL74cMGbZ4vvyPY0TuUJk2tGnxTdQWLkb
 iMOUSuYMlDyt2xrj+ncYS4Q=
X-Google-Smtp-Source: AMsMyM7M60KvOhvw/K7ssyM8e+sLv+/ovlPB066aoZ1HM5FtUZ5/B7p1egciVn/Z+HF2Z8ar+IctFw==
X-Received: by 2002:a65:4bc1:0:b0:439:e6a5:122a with SMTP id
 p1-20020a654bc1000000b00439e6a5122amr16723273pgr.443.1663760454394; 
 Wed, 21 Sep 2022 04:40:54 -0700 (PDT)
Received: from localhost ([2409:8a70:2b5:ad00:8ec6:81ff:fe70:339d])
 by smtp.gmail.com with ESMTPSA id
 x8-20020a628608000000b005409c9d2d41sm1916109pfd.62.2022.09.21.04.40.52
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Wed, 21 Sep 2022 04:40:53 -0700 (PDT)
From: Ihor Radchenko <yantar92@HIDDEN>
To: Eli Zaretskii <eliz@HIDDEN>
Subject: Re: bug#57972: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
In-Reply-To: <83k05xufhf.fsf@HIDDEN>
References: <87fsglxh24.fsf@localhost> <83k05xufhf.fsf@HIDDEN>
Date: Wed, 21 Sep 2022 19:41:46 +0800
Message-ID: <8735clx8cl.fsf@localhost>
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.2 (/)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.8 (/)

Eli Zaretskii <eliz@HIDDEN> writes:

> Would it be possible to have more info about the details?  Like what
> are org-element-cache-reset and org-element-citation-prefix-re, and
> how do they enter the picture in the above scenario?

Let's forget about org-element-citation-prefix-re for now.

org-element-cache-reset is an autoloaded function defined inside
org-element.el

Major mode body `org-mode' from org.el is calling
`org-element-cache-reset' as part of Org mode loading.

org.el does not contain (require 'org-element).
Instead, it is assumed that `org-element-cache-reset' is autoloaded by
Emacs.

Let me know if something is not clear or if you need more detailed
steps.

-- 
Ihor Radchenko,
Org mode contributor,
Learn more about Org mode at https://orgmode.org/.
Support Org development at https://liberapay.com/org-mode,
or support my work at https://liberapay.com/yantar92




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at 57972 <at> debbugs.gnu.org:


Received: (at 57972) by debbugs.gnu.org; 21 Sep 2022 11:36:11 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 07:36:11 2022
Received: from localhost ([127.0.0.1]:60915 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oay1T-0000II-2R
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 07:36:11 -0400
Received: from eggs.gnu.org ([209.51.188.92]:34340)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <eliz@HIDDEN>) id 1oay1N-0000Hk-ND
 for 57972 <at> debbugs.gnu.org; Wed, 21 Sep 2022 07:36:10 -0400
Received: from fencepost.gnu.org ([2001:470:142:3::e]:41024)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1oay18-0008CU-IN; Wed, 21 Sep 2022 07:35:59 -0400
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org;
 s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From:
 Date; bh=yloFWhirO8TrRrERag752SBVpsOA/m07fRy89Y34xno=; b=pA0fRXB6lk4617sfAtfb
 JyPnaAonFsEZipVrbWalTDjcUq4FErUP8gmplSTha3bW4rzYlbhBm+jp9jIPhVZxY2oDiYg7XAOr+
 bte4quDLT8rvgDkl7fQoKwTPC2KMcs8pmjMPhNPqM1I4OuuAfBX1eVb7RKNyQBx4n2qjt8PDqCv4u
 fF3NsUZkR7iUhyyaPvEMfXCUuka2FW8UtD/e7YQvizdeZW+H/QgaRaixK35r320ifo//f9UuAOrWj
 7d8GFbbYlza/32ZFPkmPdsVNRpqJbuiPWl4LcLPZhGdJuvNnRQZlAcxrtrZZrRUqHfQBlAYK/TY88
 7XVRBXNg6BYBbw==;
Received: from [87.69.77.57] (port=3474 helo=home-c4e4a596f7)
 by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <eliz@HIDDEN>)
 id 1oay15-0000FF-UX; Wed, 21 Sep 2022 07:35:50 -0400
Date: Wed, 21 Sep 2022 14:35:56 +0300
Message-Id: <83k05xufhf.fsf@HIDDEN>
From: Eli Zaretskii <eliz@HIDDEN>
To: Ihor Radchenko <yantar92@HIDDEN>
In-Reply-To: <87fsglxh24.fsf@localhost> (message from Ihor Radchenko on Wed,
 21 Sep 2022 16:33:39 +0800)
Subject: Re: bug#57972: 29.0.50;
 Autoloaded function raises (void-function org-element-cache-reset)
 when called within major-mode body
References: <87fsglxh24.fsf@localhost>
MIME-version: 1.0
Content-type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
X-Spam-Score: -2.3 (--)
X-Debbugs-Envelope-To: 57972
Cc: 57972 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.3 (---)

> From: Ihor Radchenko <yantar92@HIDDEN>
> Date: Wed, 21 Sep 2022 16:33:39 +0800
> 
> I am forwarding a bug report from Org mode.
> https://list.orgmode.org/4a9d4298-4af6-3e11-63c3-87bf7125f61b@HIDDEN/T/#u
> 
> I am able to reproduce the reported steps (see below) and I find that
> the void-function error is raised when calling (org-mode). `org-mode'
> body calls `org-element-cache-reset', which should be autoloaded from
> org-element.el. Yet, void-function error is raised.
> 
> I either misunderstand something about autoload or it is some kind of
> Emacs bug.
> 
> Steps to reproduce:
> 
> https://list.orgmode.org/4a9d4298-4af6-3e11-63c3-87bf7125f61b@HIDDEN/T/#u
> 
> Org mode version is the latest from
> https://git.savannah.gnu.org/cgit/emacs/org-mode.git/
> 
> > I ran this:
> > dortmann@ddo-linux:.emacs.d$ emacs -Q --debug-init asdf.el
> > ... and then ran eval-buffer.
> > 
> > Where asdf.el has this content:
> > (add-to-list 'load-path "/home/dortmann/src/git-org-mode/lisp")
> > (require 'org)
> > 
> > (setq org-capture-templates
> >        `(("c" "Item to current clocked task" checkitem
> >         (clock)
> >         "%i%?" :prepend t :empty-lines 1)))
> > 
> > Then I loaded asdf.org which has this:
> > * TODO start clock on this test item
> 
> > These two lines are in my *Messages* buffer:
> > File mode specification error: (void-function org-element-cache-reset)
> > Error during redisplay: (jit-lock-function 1) signaled (void-variable 
> > org-element-citation-prefix-re)

Would it be possible to have more info about the details?  Like what
are org-element-cache-reset and org-element-citation-prefix-re, and
how do they enter the picture in the above scenario?

TIA




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 21 Sep 2022 08:33:09 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Sep 21 04:33:09 2022
Received: from localhost ([127.0.0.1]:60587 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1oavAJ-0005Sq-6D
	for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 04:33:09 -0400
Received: from lists.gnu.org ([209.51.188.17]:48752)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <yantar92@HIDDEN>) id 1oavA6-0005SC-AT
 for submit <at> debbugs.gnu.org; Wed, 21 Sep 2022 04:33:06 -0400
Received: from eggs.gnu.org ([2001:470:142:3::10]:48724)
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <yantar92@HIDDEN>)
 id 1oavA4-00063E-Fh
 for bug-gnu-emacs@HIDDEN; Wed, 21 Sep 2022 04:32:54 -0400
Received: from mail-pj1-x1034.google.com ([2607:f8b0:4864:20::1034]:35400)
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <yantar92@HIDDEN>)
 id 1oavA2-0007Hr-Fi
 for bug-gnu-emacs@HIDDEN; Wed, 21 Sep 2022 04:32:52 -0400
Received: by mail-pj1-x1034.google.com with SMTP id
 q35-20020a17090a752600b002038d8a68fbso9477517pjk.0
 for <bug-gnu-emacs@HIDDEN>; Wed, 21 Sep 2022 01:32:49 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
 h=content-transfer-encoding:mime-version:message-id:date:subject:to
 :from:from:to:cc:subject:date;
 bh=53Ce5y4FlVWSkG2+VyCoFbCRr+FBUjb6521cYr5EEso=;
 b=n6Vq3KF/lNc0bqPQXy4KcoNJV8/LT6ONQHOZR/zCFxNQNRaKFjHSk07jIAiclBydAp
 y5yisJ3Cst7OZ+7JXXajs4c/DtRyg/+GQg1umIqZpKY1PwRAHt0S9/nklWCir5pBQTYR
 5Kry84B+9kJ4fnlsP9ozBDkwn1JgaABSP/RoFfBlfs3WRaTo+2vUGd3savlgqVZx4WIs
 U/BuelD1ByEJAbjaZRb1rv2yiXgqFaRo0HQtbFqH4Ztq0qY/m4sraS4MT+SvLua4Erj0
 cjTZTNnOvPNvZyQq7tXAB9q0uuJkyHHXBvH3umfatv3qjBtcIJ2EoYclAIDH02KHU1Qz
 3GRg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20210112;
 h=content-transfer-encoding:mime-version:message-id:date:subject:to
 :from:x-gm-message-state:from:to:cc:subject:date;
 bh=53Ce5y4FlVWSkG2+VyCoFbCRr+FBUjb6521cYr5EEso=;
 b=qi1t4N153GdLaOiy7YFeky0gdALL7HEz3KxI8ZgZOnYkW3Nt1KEdwUDBj4xXvE8hqr
 qRuvWeCtlKn3iKmMmmTJPLjQH2PdKtwTilq+z4rXCfjxos3SSvnb/kZbZN+J9YiYV2GI
 YUy5JfHA8cgLWPjQ+Fy6/WCd8J9f8O1HgPZMdZdnCoZGhFCj8nMkdzXBuJSND1FEc8lu
 XCsiyIb06o/zkF/H1vd1MYnlb2J/1jnoxOAnYXr5tl2R7Uyn2gAi1Y63Ddo4me+yFhVA
 ZKhcDXGQxRRN0WLpH/01C00QRhcBCOV27dF2BNDEHiOi7n6/fIClldE1BFJc1LS7aXQZ
 LpAQ==
X-Gm-Message-State: ACrzQf0qZRDUfhkK3hMlYzrPR6Y+9YrhryVnfcZWomVfLj68Wyxea7I2
 0Mr/C6qAjz81z1BixkPLK64Pw0ZjYpo=
X-Google-Smtp-Source: AMsMyM6YYlxhatja5yNqnhv4lBDiM52zgX15fkQL3MSXaywkcmJgBUG4dEYwlTprkyZDQbXlCCvU9g==
X-Received: by 2002:a17:902:e808:b0:178:1520:b255 with SMTP id
 u8-20020a170902e80800b001781520b255mr3593131plg.54.1663749168109; 
 Wed, 21 Sep 2022 01:32:48 -0700 (PDT)
Received: from localhost ([1.83.154.224]) by smtp.gmail.com with ESMTPSA id
 d80-20020a621d53000000b0053e6d352ae4sm1501603pfd.24.2022.09.21.01.32.43
 for <bug-gnu-emacs@HIDDEN>
 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
 Wed, 21 Sep 2022 01:32:45 -0700 (PDT)
From: Ihor Radchenko <yantar92@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 29.0.50; Autoloaded function raises (void-function
 org-element-cache-reset) when called within major-mode body
Date: Wed, 21 Sep 2022 16:33:39 +0800
Message-ID: <87fsglxh24.fsf@localhost>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
Received-SPF: pass client-ip=2607:f8b0:4864:20::1034;
 envelope-from=yantar92@HIDDEN; helo=mail-pj1-x1034.google.com
X-Spam_score_int: -17
X-Spam_score: -1.8
X-Spam_bar: -
X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001,
 RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-Spam-Score: 1.2 (+)
X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 the administrator of that system for details.
 Content preview:  Hi, I am forwarding a bug report from Org mode. I am able
 to reproduce the reported steps (see below) and I find that the void-function
 error is raised when calling (org-mode). `org-mode' body calls
 `org-element-cache-reset', which should be autolo [...] 
 Content analysis details:   (1.2 points, 10.0 required)
 pts rule name              description
 ---- ---------------------- --------------------------------------------------
 1.0 SPF_SOFTFAIL           SPF: sender does not match SPF record (softfail)
 -0.0 SPF_HELO_PASS          SPF: HELO matches SPF record
 0.2 FREEMAIL_ENVFROM_END_DIGIT Envelope-from freemail username ends
 in digit (yantar92[at]gmail.com)
 0.0 FREEMAIL_FROM          Sender email is commonly abused enduser mail
 provider (yantar92[at]gmail.com)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.1 (--)

Hi,

I am forwarding a bug report from Org mode.
https://list.orgmode.org/4a9d4298-4af6-3e11-63c3-87bf7125f61b@HIDDEN/T/=
#u

I am able to reproduce the reported steps (see below) and I find that
the void-function error is raised when calling (org-mode). `org-mode'
body calls `org-element-cache-reset', which should be autoloaded from
org-element.el. Yet, void-function error is raised.

I either misunderstand something about autoload or it is some kind of
Emacs bug.

Steps to reproduce:

https://list.orgmode.org/4a9d4298-4af6-3e11-63c3-87bf7125f61b@HIDDEN/T/=
#u

Org mode version is the latest from
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/

> I ran this:
> dortmann@ddo-linux:.emacs.d$ emacs -Q --debug-init asdf.el
> ... and then ran eval-buffer.
>=20
> Where asdf.el has this content:
> (add-to-list 'load-path "/home/dortmann/src/git-org-mode/lisp")
> (require 'org)
>=20
> (setq org-capture-templates
>  =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 `(("c" "Item to current clocked task" che=
ckitem
>  =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 (clock)
>  =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 "%i%?" :prepend t :empty-lines 1)))
>=20
> Then I loaded asdf.org which has this:
> * TODO start clock on this test item

> These two lines are in my *Messages* buffer:
> File mode specification error: (void-function org-element-cache-reset)
> Error during redisplay: (jit-lock-function 1) signaled (void-variable=20
> org-element-citation-prefix-re)

In GNU Emacs 29.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
 3.24.34, cairo version 1.16.0) of 2022-09-07 built on localhost
Repository revision: 473313d2a85a7ae73daf5cc7c205f6285286eecf
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12101004
System Description: Gentoo Linux

--=20
Ihor Radchenko,
Org mode contributor,
Learn more about Org mode at https://orgmode.org/.
Support Org development at https://liberapay.com/org-mode,
or support my work at https://liberapay.com/yantar92




Acknowledgement sent to Ihor Radchenko <yantar92@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#57972; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Wed, 21 Sep 2022 14:15:01 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.