From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id mK0NDOiNxmW44AAA62LTzQ:P1 (envelope-from ) for ; Fri, 09 Feb 2024 21:41:12 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id mK0NDOiNxmW44AAA62LTzQ (envelope-from ) for ; Fri, 09 Feb 2024 21:41:12 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=lW3lN05c; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1707511272; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=5P19NGkb9yYzgs/IfLBI+MzXOcKVRtWXiSgU4Wq816I=; b=EGeNMGuuX1eos9QzoooSw8DLpwyrjCA5sJNF71qdzwgnkSRMKWU3bQqSzp4FlHTVml5dve EZGYbneuw9+PLW4SkXHr5iDHl7tAWI9HGu3yjmHEkecXmsUcsOnJCy8fxxXLNIuHP5ArLT ECzfqUCwhAnZDJDrCduS9HkvK2IV1rk/7q6XKPoZ7O9WSFR6kk9gPq0knhQGeufgA9WgQs hvj+5zn2V9mw4vFlGdSFKWwEdiBOOtHFdXQrDX3Ib7Q5jB4+TbxQtRVLJCMmK4eh6a8Vnb baMdEpV5Rx7wvUqc7mwZtxnrqyO5Q5M+5W24LQgQViNp4jRUm87viU398DnyUw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=lW3lN05c; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Seal: i=1; s=key1; d=yhetil.org; t=1707511272; a=rsa-sha256; cv=none; b=fIQ/xEJUKJj68PBMpH3Cr2jDbsj2s+nhRG3zo4UiOim5KVlrb7VcQpbAyebMkl+Iwi1b6Y lh30Zv0vRLRW7ZS4LfpB6QnVkvPEcorlLbd+1fprBmkjOzKFOpFucLbH+TPJ/Jd85m52Vj FwnRtQm1+h3HkU9t6hm8z8CSki6K0Jf4C7+THCKxCCjNDFXaiQlLUlqDMNeBVg4innxXLT UFCww5nWYVcBPLQ0zu/hDeIqg16y0FT8an9hNCTTLl0RUr7Ldqw0iwZt5IuUHw0+R80zMd VZaTP3jYVaOfmfShROCkZYf1gSOacQV5+Xl83SWhVeX7uFnORLSCfp5+5Kuutw== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id D4A1117BD0 for ; Fri, 9 Feb 2024 21:41:11 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rYXfV-0003Hh-A7; Fri, 09 Feb 2024 15:40:17 -0500 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 1rYXfS-0003HJ-Qr for emacs-orgmode@gnu.org; Fri, 09 Feb 2024 15:40:14 -0500 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rYXfC-0008FJ-Gq for emacs-orgmode@gnu.org; Fri, 09 Feb 2024 15:40:00 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 7D287240103 for ; Fri, 9 Feb 2024 21:39:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1707511196; bh=mzDF8ldabsZ6cAdemcfWHnpIBV+PHjuJ4ZwQWMjsvCc=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=lW3lN05c5DC6gFpLYOMVEVqr8G2sTNtxZqlR+eYsj5ONtOfQOpEy/jwdPxRc1xd5g YQLccIVUhzWqtzH3q+PebU8Pw1qU5FwJVoybCgu+0rAwUXigd7NgDLUQ+1iJmuTBTW bUQFviG9q8+Z+Qhaj5Wd3Xu8KThn7iVWEbHzcATMToWrrFSP45M3drHANUXLBq7Rfv hgPiJOHzq4Fc6zqKqibmiMjZ/UlpxTfFaja9Pyzxz4T1NMyX97DgBDy2aCOIg66Fca O0shIfgnlC73OIjGGsIkZTqROTeEDe5PfilqemkRcfCRWZy7fYCEhJIQSIRrBB0dmZ meXw3uoWQZuvw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4TWm1m0YMdz9rxK; Fri, 9 Feb 2024 21:39:55 +0100 (CET) From: Ihor Radchenko To: Tommy Kelly Cc: emacs-orgmode@gnu.org Subject: Re: [BUG] Invalid capture datetree capture templates (newly introduced) [9.7-pre (release_9.6.18-1145-g10d286 @ /home/jds6696/.emacs.d/straight/build/org/)] In-Reply-To: References: <87zfwccpvs.fsf@gmail.com> <87h6ik49eb.fsf@localhost> Date: Fri, 09 Feb 2024 20:43:26 +0000 Message-ID: <87a5o99xn5.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=yantar92@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -7.68 X-Migadu-Scanner: mx13.migadu.com X-Spam-Score: -7.68 X-Migadu-Queue-Id: D4A1117BD0 X-TUID: 6V7qbd1rpJbJ Tommy Kelly writes: > C) entry (file+olp+datetree "test-datetree.org" "H1 "H2") ;; > filename plus heading and sub-heading > > Then I'd expect A) to use a datetree rooted at the file top level; B) > to use one underneath heading "* H1"; and C) to use one underneath ** > H2" (which itself is underneath "* H1"). > And in each case I'd expect it to create a new datetree at the > specified location if one didn't already exist. > > HOWEVER, it looks like that can break if there is already one or more > datetrees anywhere in the file AT A LEVEL BELOW THAT specified by the > template. > In that case, the position specified by the template is simply > ignored. Instead, the captured item is filed at first occurring > datetree of the above kind. > To be clear, that's even if there is also a pre-existing datetree at > the correct, template-specified location but further down the file. Are you sure that what you describe is newly introduced? I'd expect this exact behavior since forever, judging from how `org-datetree--find-create' is implemented. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at