From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id sJLFKSd46WBJCAEAgWs5BA (envelope-from ) for ; Sat, 10 Jul 2021 12:36:23 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id qJh7JSd46WAQPAAAbx9fmQ (envelope-from ) for ; Sat, 10 Jul 2021 10:36:23 +0000 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 5764D15E95 for ; Sat, 10 Jul 2021 12:36:22 +0200 (CEST) Received: from localhost ([::1]:52438 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m2ALN-00010i-CA for larch@yhetil.org; Sat, 10 Jul 2021 06:36:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:51686) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m2AKv-00010a-3A for emacs-orgmode@gnu.org; Sat, 10 Jul 2021 06:35:53 -0400 Received: from mail-pj1-x1036.google.com ([2607:f8b0:4864:20::1036]:41683) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1m2AKr-0004yO-SX for emacs-orgmode@gnu.org; Sat, 10 Jul 2021 06:35:52 -0400 Received: by mail-pj1-x1036.google.com with SMTP id oj10-20020a17090b4d8ab0290172f77377ebso7539048pjb.0 for ; Sat, 10 Jul 2021 03:35:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=utec-edu-pe.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:mime-version; bh=UcLQjLVTecap5gj5ta01ySB+46jaz0PuAG4r9Ias79Y=; b=YQVECaYbzGsJ+3t6K/7ng3CLQgV7ciDhlMBGPfbJuWwC6cVhTygJHYcYmZx1svf1EV Bg3ZkefuXDPpwZJcazSHO671mu98C4cLH8xigUHQDtRsX7vCYbDYy3H3Gu5FoGz2V6oc QUUiQx3wAa3ALzHDaIaObz26obzV3/3J6AvqE9Y82vAm/3OB6jLEQpDMKRAkC3NjMX01 KrFukZ77UxnOmsIwPPE5l2xbp5Vm4eUwsK4oKP9A5JowKjMy9FredjYrm0s2UvKe89Y3 DGuaU6T2osYb4Sha4kJujeBroQ4wqTu5yfgCKgExigwfLlHAkNYFumWa0X678F8tnrTK nA+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version; bh=UcLQjLVTecap5gj5ta01ySB+46jaz0PuAG4r9Ias79Y=; b=Kw8uEBl3tfA4sVe3ERQUOvCGrRMqPf0pX8PYWM6H6EDUkXdGCJIhDxYMtJwbiUdCm6 Uqh5anAugo18lqtSrtdZTfaGluWXfCOBO4sY4T4mu1be8tb3+aLxMASAjsCllvxc2AUg Ot5lBa2s295f0QK0XxNJgWhUT1K7O7Nefa0reWtU9hd8KruDv0g0fDmGbzv3B78d97s2 T3NYevdtTTy0gcn2QdeGmLNKza+ONZmKkSyjzU/GiqW3uy6hzZvTcFs2ON8tAur18HXc OCk1qqBWdryAY47rX+nr1mEY1CFsSqeYdykpdGRecnRkWG5bIddBDXy1FLuSnQbUcAa7 Pydw== X-Gm-Message-State: AOAM5316icHt4tb32omKw5Y3uIank53sZxQubHkSJoh/S2dhGgRIKiLE jRfU7+4KyOCzfHXc23DermehLXajSKdM3wdWt5EOKC/KvXKxoNYHOjO7nHvBPkc1812RtgCzMiT fi14z7Q7qPMpH1oMRS/Y= X-Google-Smtp-Source: ABdhPJzabP2ugCvOQdXl2YRdeaqxeLMeVcsU53Ep8L37lUqxE9SZNCW2m6oiQwBH5W220kAL+eZ6KA== X-Received: by 2002:a17:902:a9c1:b029:129:cfd5:a948 with SMTP id b1-20020a170902a9c1b0290129cfd5a948mr14042004plr.55.1625913347133; Sat, 10 Jul 2021 03:35:47 -0700 (PDT) Received: from r1 ([190.239.232.58]) by smtp.gmail.com with ESMTPSA id lt14sm8258235pjb.47.2021.07.10.03.35.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 10 Jul 2021 03:35:46 -0700 (PDT) From: Rodrigo Morales To: emacs-orgmode@gnu.org Subject: [bug] Setting org-id-link-to-org-use-id to t creates IDs properties when tangling Date: Sat, 10 Jul 2021 05:35:21 -0500 Message-ID: <87tul2ihhy.fsf@utec.edu.pe> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=2607:f8b0:4864:20::1036; envelope-from=rodrigo.morales@utec.edu.pe; helo=mail-pj1-x1036.google.com X-Spam_score_int: 8 X-Spam_score: 0.8 X-Spam_bar: / X-Spam_report: (0.8 / 5.0 requ) BAYES_50=0.8, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, 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-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 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" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1625913382; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=UcLQjLVTecap5gj5ta01ySB+46jaz0PuAG4r9Ias79Y=; b=H/RBQmUbDeukKSQlQFoN3UPLt5W9yTijW44FIcNY3vHtVOnjmLqpt8OwuiVaKMyP9hAtFW y30s7EbcFpVg5anFKtIxdw0a/ALuf33efA00frr4YJwT8Dysby7fsYT8pEHLsUxcSmZuRY P4ZEy4G7MgNd8oJu5Pz0+v5YrsF4OBLX3VYJQx0uDIBd5dFfZgJYTxRT2b0o7G7fBEdvzn qheuv0gNqv78fEupuX2RRqZKjE2uxGmlpc1GQ+GozEg2drvHWTrBjzZ5fY66PsONX+sHUx IeC9YoPuEA5PuoBUdRaItAvevF+qupSjSrE6MK7y0Xi0DEzsTD90P3K1LHNR+Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1625913382; a=rsa-sha256; cv=none; b=ROdG5+egEHGVvK6PtWvMsbnE3jFrLn5o/2qbtUFnhVoPEGc6UM765FbQvSSXDtiOHEnKWq A2EPnhKSTA5G5mEgmmNFvlQRb4/yINQ2FMHmbSRGRYLkDbF4O5z0rnrY+J+FQjn1Jx4nvG +ZZej52UYgW2preIX/WtKp+fSMwIWrhLjkmRCfwxxxT91Fu1gKXhzcXa3crbUagwbeBwRY eCtqVr8qhMN+kH2zmLqKNpAS8b9sl/hMEBoz7LfWNGichc3S6LAnl0niFUXZO+TQzEnxOG dj0Bg4VkinJgZbhgzXCYYGhdWnWD5qlHl+QzeWtCxbiL5RwAU5dgwFn9hyGRkw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=utec-edu-pe.20150623.gappssmtp.com header.s=20150623 header.b=YQVECaYb; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -1.60 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=utec-edu-pe.20150623.gappssmtp.com header.s=20150623 header.b=YQVECaYb; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 5764D15E95 X-Spam-Score: -1.60 X-Migadu-Scanner: scn0.migadu.com X-TUID: AWnF4L8plaMT --=-=-= Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable * The issue When setting org-id-link-to-org-use-id to t, an :ID: property is created for each headline that contain at least one code block that is tangled. * Reproducing this issue 1. Start emacs -Q 2. Open a "*.org" file at a location where you have write permissions (this is because, apparently, tangling only works when the file is correctly saved so this way we get rid of this possible issue) 3. Insert the following minimal working example into the buffer (you can find the Org Mode file attached to this mail) #+BEGIN_SRC org ,* foo ,#+HEADER: :tangle ~/Downloads/main.txt ,#+BEGIN_SRC text a ,#+END_SRC ,* bar ,#+HEADER: :tangle ~/Downloads/main.txt ,#+BEGIN_SRC text a ,#+END_SRC ,* fizz ,#+BEGIN_SRC text a ,#+END_SRC #+END_SRC 4. Execute the following commands #+BEGIN_SRC emacs-lisp (require 'org-id) (setq org-id-link-to-org-use-id t) #+END_SRC 5. Now, execute org-babel-tangle (C-c C-v C-t). At this point, a id property is created for the "foo" and "bar" headlines because those are the only headlines that contain a code block. This is what I got in emacs -Q #+BEGIN_SRC org ,* foo :PROPERTIES: :ID: 358560b4-2426-4d42-a498-ae16195daf3a :END: ,#+HEADER: :tangle ~/Downloads/main.txt ,#+BEGIN_SRC text a ,#+END_SRC ,* bar :PROPERTIES: :ID: 02217461-a744-42b2-b582-1a836568d686 :END: ,#+HEADER: :tangle ~/Downloads/main.txt ,#+BEGIN_SRC text a ,#+END_SRC ,* fizz ,#+BEGIN_SRC text a ,#+END_SRC #+END_SRC * Personal thoughts In my opinion, this is undesired behavior because the goal of org-id-link-to-org-use-id isn't creating an ID property for each headline when performing tangling. * Major undesired consequences The following is an scenario in which this issue causes major undesired consequences: Consider the following scenario + you have 1000 headlines in an Org Mode file + all of those headlines don't have an ID property (because you are not interested in uniquely identifying all of those headlines through an ID) =20 + all of those headlines contain at least one code block that is tangled Because of this issue, the following would be added for each headline #+BEGIN_SRC org ,* my headline :PROPERTIES: :ID: <> :END: #+END_SRC and this have the following undesired consequences + You would end up with 3000 lines in your Org Mode file because of the id properties even when you weren't interested in creating an ID for each of those headlines. =20 + You would have 1000 more entries in org-id-locations-file (again, even where you weren't interested in creating an ID for each of those headlines) --=20 La informaci=F3n contenida en este e-mail y sus anexos es confidencial,=20 privilegiada y est=E1 dirigida exclusivamente a su destinatario, en=20 consecuencia, solo puede ser utilizada por aquel. Si usted no es el=20 destinatario original, no deber=E1 examinar, usar, copiar o distribuir este= =20 mensaje o la informaci=F3n que contiene. Si lo recibe por error, por favor= =20 reenv=EDelo a la persona que se lo envi=F3 y elim=EDnelo. Cualquier retenci= =F3n o=20 uso total o parcial no autorizada de este mensaje est=E1 estrictamente=20 prohibida y sancionada por ley. --=-=-= Content-Type: text/plain Content-Disposition: attachment; filename=main.org * foo #+HEADER: :tangle ~/Downloads/main.txt #+BEGIN_SRC text a #+END_SRC * bar #+HEADER: :tangle ~/Downloads/main.txt #+BEGIN_SRC text a #+END_SRC * fizz #+BEGIN_SRC text a #+END_SRC --=-=-= Content-Type: text/plain -- [[[ If you see a signature in spanish below/above this message, please omit it. It is automatically inserted in all my messages due to the internal privacy policies of the organization that owns the domain of my email address. ]]] --=-=-=--