Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-06-14 Thread Ihor Radchenko
Ignacio Casso writes: >> Please don't use ditto. (what does it even mean?) > > It means the same thing again. I saw it in the message of the Emacs > commit I referenced earlier in this thread, so I assumed it was standard > practice. I have replaced it with "The same". But if the problem is that

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-06-14 Thread Ignacio Casso
>> Subject: [PATCH] use `set-default-toplevel-value' in `defcustom' setters >^Use > >> * lisp/ob-lilypond.el (org-babel-lilypond-commands): use >^Use >> `set-default-toplevel-value' instead of `set' or `set-default' in >>

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-06-13 Thread Ihor Radchenko
Ignacio Casso writes: >> LGTM! Unless others have objections, I am inclined to merge the patch >> fully. But please add changlog entries to the commit message. > > Done. I attach the patch with the new commit message. Thanks! Some more comments. > Subject: [PATCH] use

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-06-12 Thread Max Nikulin
On 11/06/2022 20:32, Ihor Radchenko wrote: Ignacio Casso writes: Then we should decide if we want to use autoload cookies for custom variables to make this work also with lexical binding. Otherwise, code like the snippet above would produce an error in Emacs 29, and in Emacs 27 the let binding

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-06-11 Thread Ignacio Casso
> LGTM! Unless others have objections, I am inclined to merge the patch > fully. But please add changlog entries to the commit message. Done. I attach the patch with the new commit message. >From 26d157aedfaf1496174682a1f9033d83160a06c2 Mon Sep 17 00:00:00 2001 From: Ignacio Casso Date: Sat,

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-06-11 Thread Ihor Radchenko
Ignacio Casso writes: > Then we should decide if we want to use autoload cookies for custom > variables to make this work also with lexical binding. Otherwise, code > like the snippet above would produce an error in Emacs 29, and in Emacs > 27 the let binding would be ignored (although at least

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-06-11 Thread Ignacio Casso
Hello, The bug I reported about this to the Emacs devel mailing list (https://debbugs.gnu.org/cgi/bugreport.cgi?bug=54399) has now been closed, and some documentation has been updated in commit 071722e41120. Basically, the problem is that in order for (let ((custom-variable local-value) ...)

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-15 Thread Ignacio Casso
> I'll write now the email to emacs-devel with all these issues and > mention in this thread the corresponding debbugs thread in case anyone > wants to follow it. 54...@debbugs.gnu.org

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-15 Thread Ignacio Casso
>>> My recommendation would be to come up >>> with a non-org specific example which reproduces the behaviour and then >>> ask on emacs-devel, using the example to demonstrate the issue. >> >> I agree. I'm on it. After trying to build a simple example I have realized a part of my analysis was

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-15 Thread Ignacio Casso
>>> For `defcustom' autoload generates no more than >>> >>> (defvar org-capture-templates nil "...") >>> >>> It seems, behavior depends on whether `org-capture-templates' has the :set >>> attribute. >> Not really, all defcustoms have a :set attribute, be it passed >> explicitly as a

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-15 Thread Max Nikulin
On 15/03/2022 02:43, Ignacio Casso wrote: I've also investigated the issue a little bit further and wrote and email with my conclusions about the same time Max wrote his. I comment inline about a few of your thoughts: For `defcustom' autoload generates no more than (defvar

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-14 Thread Tim Cross
Ignacio Casso writes: >> Regardless, I don't think having the situation where the programmer must >> know (guess) whether autoload will/could execute during the evaluation >> of code they write is tenable and am beginning to suspect it may be an >> Emacs bug OR a subtle bug in org-mode as a

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-14 Thread Ignacio Casso
I've also investigated the issue a little bit further and wrote and email with my conclusions about the same time Max wrote his. I comment inline about a few of your thoughts: > For `defcustom' autoload generates no more than > > (defvar org-capture-templates nil "...") > > It seems, behavior

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-14 Thread Tim Cross
Max Nikulin writes: > On 12/03/2022 02:59, Tim Cross wrote: >> Ignacio Casso writes: > >>>(let ((org-capture-templates >>> '(("d" "default" entry >>> (file+headline org-default-notes-file "Tasks") >>> "* %?" >>> (org-capture nil "d"))) >>> >>> I

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-14 Thread Ignacio Casso
> While I don't know if this is a bug, it certainly doesn't seem to be > doing the right thing from an 'intuitive' point of view. I would expect > when a variable is bound to a value inside a let and a function is then > called which uses that variable, the initial let bound value should be >

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-14 Thread Max Nikulin
On 12/03/2022 02:59, Tim Cross wrote: Ignacio Casso writes: (let ((org-capture-templates '(("d" "default" entry (file+headline org-default-notes-file "Tasks") "* %?" (org-capture nil "d"))) I put an autoload cookie myself and it doesn't fix it,

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-11 Thread Tim Cross
Ignacio Casso writes: > Max Nikulin writes: > >> Ignacio, I think, you can add (require 'org-capture) inside your >> function just before `let' and it would work almost as lazy loading. > > Thanks, I was already using (require 'org-capture) in my init file to > solve this. As I said, it's not

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-11 Thread Ignacio Casso
Max Nikulin writes: > Ignacio, I think, you can add (require 'org-capture) inside your > function just before `let' and it would work almost as lazy loading. Thanks, I was already using (require 'org-capture) in my init file to solve this. As I said, it's not really a problem for me, I was

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-11 Thread Max Nikulin
On 11/03/2022 01:00, Ignacio Casso wrote: Max Nikulin writes: On 10/03/2022 19:53, Ignacio Casso wrote: For example, if we call this: (let ((org-capture-templates '(("d" "default" entry (file+headline org-default-notes-file "Tasks") "* %?"

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-10 Thread Ignacio Casso
Max Nikulin writes: > On 10/03/2022 19:53, Ignacio Casso wrote: >> For example, if we call this: >>(let ((org-capture-templates >> '(("d" "default" entry >> (file+headline org-default-notes-file "Tasks") >> "* %?" >> (org-capture nil "d"))) >>

Re: [BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-10 Thread Max Nikulin
On 10/03/2022 19:53, Ignacio Casso wrote: For example, if we call this: (let ((org-capture-templates '(("d" "default" entry (file+headline org-default-notes-file "Tasks") "* %?" (org-capture nil "d"))) It produces the error: (error "No

[BUG] org-capture autoload bug? [9.5.2 (9.5.2-gfbff08 @ /home/ignacio/.emacs.d/elpa/org-9.5.2/)]

2022-03-10 Thread Ignacio Casso
Hello, I think I've found a bug with org-capture autoload. If the first time you use org-capture before it's actually loaded is within a let form binding org-capture-templates, it produces an error saying that the template was not found. For example, if we call this: (let