From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:700:3204::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id 8EmtIvb3n2UUZQAAkFu2QA (envelope-from ) for ; Thu, 11 Jan 2024 15:15:18 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id UCfpHPb3n2UbLwEAe85BDQ (envelope-from ) for ; Thu, 11 Jan 2024 15:15:18 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=VH4obhZr; dmarc=pass (policy=none) header.from=posteo.net; 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" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1704982518; a=rsa-sha256; cv=none; b=ECrbHntkTX0H/jSZkfwuFARALzorMfL62p1RwyBqzJwplb5MmvAw9c9MlJjzshr8/XYUgX gE6KhJSRKvFouQTrhHOIwNs+CWrU7qAG3hyIGLDYJjpER3lBWj9yxE4XDufptr63z6HsHf KSh8ua5FOQF7VSTDOJVPLGZA9vX32+kZeaojX/yuOTFJrabbvYeGOmoSVETqDbVZY3+NI4 wcrLpGoXR6EeCfRhsZpw6Px7SXwCZKkTPAbHCjpCG4GBjmN3BNoWbhHgoHPv+BSeisRHiB izEAriDKhoXUz+p0SIWUvsEpL+uGqB4gXOV9Bny3oWG3sAvloxnTkUsEW2Tncg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=VH4obhZr; dmarc=pass (policy=none) header.from=posteo.net; 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" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1704982518; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=90q6Z5mql757UxaCc+C4AW0+u10+yTY/gSWOvNDy8d8=; b=oal3MCvKZ6DOd1UWDGM6VFpVo1vqbtnSHh9npSmkfkNgRsby+f2jdP25TCdpcs8URRtMO2 58w7yk/lBt7riL03BjMe9KmT6L0ry3UQmrfmr7wT7ikxAXJk9K4VcqTcs7W2ue0ypNIDr1 oS6FZ05yy9YeZUwgm3r4Kjt8vTf9PJz5iJ+XnFLdZKXoVU9qsVQvocrIonaxb9PUW8lLNW Wcx2Etyt8+TdPgi+XtxnoyD7aH1GUhMd/KMLEayY6X28LKD652LE73HXOPpT+PVwPoP8rz JFP+ahZZIGhYjLe9lkdR3biWA3fJFqZRZE594An+PorpkNz1FP6bePKUG0uqow== 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 173D515C0B for ; Thu, 11 Jan 2024 15:15:17 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rNvp8-0001uM-1x; Thu, 11 Jan 2024 09:14:22 -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 1rNvp6-0001u4-P8 for emacs-orgmode@gnu.org; Thu, 11 Jan 2024 09:14:20 -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 1rNvp4-00055N-5X for emacs-orgmode@gnu.org; Thu, 11 Jan 2024 09:14:20 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id E53F0240101 for ; Thu, 11 Jan 2024 15:14:14 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1704982454; bh=ypIYbpvrTO8SrF1wpHM0gI/3yglSweXHo3WYCLQvOSs=; h=MIME-Version:Content-Transfer-Encoding:Date:From:To:Cc:Subject: Message-ID:From; b=VH4obhZr2cKOu3k5Hfd2RrneYCDjkBeB5doFdVwCE61bORWWX67yEEMTLlPrUHtwI AC4yAkyddcjNRlOeoUgsPJt8GS0DrLWlJODG6qUIrWEcwTNJoxY3EcYI6mia3k34Mo RaQrHEqViYSOKKpO+tXBTCDO5esOTipHWa7kE1TvAyy87f7wuuTWKU5dpy9txvPyXX JrWWIP9DamwMkFRDEAw1W5lG4L6uBPY3/qsCHpOMJFev5JpOUAcPvIKe9Xdg9PxHzV tDcINYbkPbXNU3NU/z1ZQ8S1A9CgMH/eQVHZrS9LkttVA1XBc44SqzdzXe+Vj4+Uad j36LFvW5PQRaw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4T9mr62VMSz6ty6; Thu, 11 Jan 2024 15:14:14 +0100 (CET) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Thu, 11 Jan 2024 14:14:14 +0000 From: gerard.vermeulen@posteo.net To: Ihor Radchenko Cc: Emacs orgmode Subject: Re: [BUG]: unexpected behavior related to org-indent-block In-Reply-To: <87mstcjbas.fsf@localhost> References: <87mstcjbas.fsf@localhost> Message-ID: <7e14e605f4b2a9f802a75b91247245f2@posteo.net> Received-SPF: pass client-ip=185.67.36.66; envelope-from=gerard.vermeulen@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_H5=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-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -8.82 X-Spam-Score: -8.82 X-Migadu-Queue-Id: 173D515C0B X-Migadu-Scanner: mx13.migadu.com X-TUID: dTAAZuV8Nfwe On 11.01.2024 13:37, Ihor Radchenko wrote: > gerard.vermeulen@posteo.net writes: > >> Below, I show 2 commands to be run with point on a source block. >> I expect that those commands modify an Org file identically, but >> they do not. It fails when `org-indent-block' is called in a >> loop after each `(insert (org-element-interpret-data copy))' and >> it works when `org-indent-block' is called in a separate loop >> after insertion of all `(org-element-interpret-data copy)'s: >> ... >> Example block: >> --- >> #+begin_src emacs-lisp >> >> #+end_src >> --- >> make-2-indent-fails results in >> --- >> #+begin_src emacs-lisp >> copy 1 >> #+end_src > > I cannot reproduce. > I am seeing > > make-2-indent-fails results in > --- > #+begin_src emacs-lisp > copy 1 > #+end_src > #+begin_src emacs-lisp > copy 2 > #+end_src > > > On the latest main. This is strange: I pulled the latest main and created a clean org-emacs directory where I put a minimal init.el reading: (when (eq system-type 'darwin) (setopt ns-alternate-modifier nil ns-command-modifier 'meta ns-right-command-modifier 'super)) (push (expand-file-name "~/VCS/org-mode/lisp") load-path) (require 'org) After emacs --init-directory org-emacs, I get (code in the result blocks got now indented): Example block: --- #+begin_src emacs-lisp #+end_src --- make-2-indent-fails results in --- #+begin_src emacs-lisp copy 1 #+end_src --- make-2-indent-works results in --- #+begin_src emacs-lisp copy 1 #+end_src #+begin_src emacs-lisp copy 2 #+end_src --- I have no idea what I can do now. My Emacs is also recent main and built by me with minimal configure options.