From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paul Rankin Subject: Bug: org-set-tags duplicates tags in org-tag-persistent-alist Date: Mon, 11 May 2015 15:09:12 +1000 Message-ID: Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2098\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:49463) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yrfxw-0001mj-JE for emacs-orgmode@gnu.org; Mon, 11 May 2015 01:09:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Yrfxt-0000xo-8H for emacs-orgmode@gnu.org; Mon, 11 May 2015 01:09:20 -0400 Received: from out4-smtp.messagingengine.com ([66.111.4.28]:41947) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Yrfxt-0000xk-0G for emacs-orgmode@gnu.org; Mon, 11 May 2015 01:09:17 -0400 Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 216DD20640 for ; Mon, 11 May 2015 01:09:16 -0400 (EDT) Received: from [100.64.32.222] (unknown [202.0.190.43]) by mail.messagingengine.com (Postfix) with ESMTPA id 3DB9EC00011 for ; Mon, 11 May 2015 01:09:14 -0400 (EDT) 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.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org When setting org-tag-alist or org-tag-persistent-alist, calling = org-set-tags or org-agenda-set-tags will populate select with both alist = tags and any tags from tagged subheadings. To reproduce: $ cat tmp.org * TODO task :tag1: $ emacs -Q (setq org-tag-persistent-alist '(("tag1" . ?1) ("tag2" . ?2))) M-x eval-last sexp M-x find-file RET tmp.org M-x org-set-tags Inherited: Current: tag1 [1] tag1 [2] tag2 [t] tag1 "tag1" is duplicated. This also occurs if tmp.org is added to agenda and org-agenda-set-tags = is called, however this bug *compounds* with each additional agenda file = containing tagged subheadings, e.g. if org-agenda-files contains five = org files, each with subheadings tagged :work: then org-agenda-set-tags = will populate with six :work: selections (org-tag-persistent-alist plus = each additional file). This bug appears to have been first reported back in 2012 but not = investigated: https://lists.gnu.org/archive/html/emacs-orgmode/2012-12/msg00470.html GNU Emacs 24.5.1 (x86_64-apple-darwin14.3.0, NS apple-appkit-1347.57) of = 2015-04-21 on Pauls-MacBook-Pro.local Org-mode version 8.2.10 (8.2.10-40-gc763fa-elpa @ = /Users/Paul/.emacs.d/elpa/org-20150504/)