From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Abrahamsen Subject: Re: Possible to exclude/include tags for agenda custom commands? Date: Thu, 20 Feb 2020 11:51:28 -0800 Message-ID: <878skxavgf.fsf@ericabrahamsen.net> References: <8736bfxwu0.fsf@bzg.fr> <874kvl8aoc.fsf@ericabrahamsen.net> <87d0a99nph.fsf@gnu.org> <87v9o16tga.fsf@ericabrahamsen.net> <87mu9d6q0m.fsf@ericabrahamsen.net> <87imk12i19.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:37402) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j4rrC-0001qY-HH for emacs-orgmode@gnu.org; Thu, 20 Feb 2020 14:51:36 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j4rrB-0005uA-Fg for emacs-orgmode@gnu.org; Thu, 20 Feb 2020 14:51:34 -0500 In-Reply-To: <87imk12i19.fsf@gnu.org> (Bastien's message of "Thu, 20 Feb 2020 20:08:34 +0100") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane-mx.org@gnu.org Sender: "Emacs-orgmode" To: Bastien Cc: emacs-orgmode@gnu.org Bastien writes: > Hi Eric, > > Eric Abrahamsen writes: > >> I'll also note that, while this works perfectly well, every time I >> refresh my custom agenda I see: >> >> Making org-agenda-tag-filter buffer-local while locally let-bound! > > Can you send enough information so that we can reproduce the problem? Yes, that wasn't a very helpful report, was it? First of all, here's the custom command I'm using, to organize an upcoming trip to New York: ("n" "New York Feb 2020" ((tags-todo "nyfeb2020") (agenda "is this string meaningless?" ((org-agenda-start-day "2020-02-25") (org-agenda-span 15)))) ((org-agenda-tag-filter '("+nyfeb2020")))) I edebug `org-agenda-redo', and hit "g". In this function, `org-agenda-tag-filter' is nil. I don't know if it's supposed to be or not, but it is. The error arises out of `org-agenda-run-series', so we go there, and find it comes from `org-let': (let ((org-agenda-tag-filter '("+nyfeb2020"))) (org-agenda-prepare name)) `org-agenda-run-series' gets called twice every time I update the agenda; the error only arises from the first time. The `org-agenda-tag-filter' variable is buffer-local to my custom agenda, which is why Emacs complains that it's being let-bound. I don't see where `org-agenda-tag-filter' is made buffer-local. I hope that helps! Eric