From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id iPaVDoLZW2O0+wAAbAwnHQ (envelope-from ) for ; Fri, 28 Oct 2022 15:30:42 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id QDiNDoLZW2NSdwEA9RJhRA (envelope-from ) for ; Fri, 28 Oct 2022 15:30:42 +0200 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 0614120539 for ; Fri, 28 Oct 2022 15:30:42 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ooPQL-00060E-1h; Fri, 28 Oct 2022 09:29:26 -0400 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 1ooPQ9-0005fu-KX for emacs-orgmode@gnu.org; Fri, 28 Oct 2022 09:29:13 -0400 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 1ooPPy-00065H-J4 for emacs-orgmode@gnu.org; Fri, 28 Oct 2022 09:29:13 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 276A0240104 for ; Fri, 28 Oct 2022 15:28:59 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1666963739; bh=rXUOIw3o06uacXeui4wlGZxeksWqX/yndeDXNhSmnCU=; h=From:To:Cc:Subject:Date:From; b=HthzjTrUDTnAoL2bRRJ1f5cyLyV/PHmZMuzWF+0GRjZi7k2ciWkeNPTscZgPC51pv FCFdKNi4cEsh8Suyq5iarye9wf4Uu9aD0+9dyrJ+X7R2xCOPK7TB9EO3IbMvDvazur Fy+jvFNZsFPiCW9xN358k47KxgDZGrM6BGZAOcC1kxFLmLPtem+9YHo5Te2r0A+XxV cgBR8DfeFzwaVAnNbIhMWZFkRnp8bNwbr7tDOZLx56ZzH7O0qowhpSqbodS/hARanC jTJcErDe0SPBc3BhzNLe+dAfBJL18mdh2CNAiG8IVHX29WbGvewanv2qnWPll4W8zn OWYWeL/Ia3R6w== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4MzNfw3ndKz9rxS; Fri, 28 Oct 2022 15:28:55 +0200 (CEST) From: Ihor Radchenko To: Rudolf =?utf-8?Q?Adamkovi=C4=8D?= Cc: Ihor Radchenko , emacs-orgmode@gnu.org Subject: Re: Org 9.6-pre and Bash sessions In-Reply-To: References: <87edvbysqc.fsf@localhost> <87r0z6j1b1.fsf@localhost> <87pmel68y6.fsf@localhost> <87o7u432tl.fsf@localhost> <87a65o15ut.fsf@localhost> <87fsffqi49.fsf@localhost> <87wn8lorc1.fsf@localhost> Date: Fri, 28 Oct 2022 13:29:38 +0000 Message-ID: <87v8o4krel.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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_H2=-0.001, SPF_HELO_NONE=0.001, T_SPF_TEMPERROR=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: , Sender: "Emacs-orgmode" Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1666963842; 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=oZfMqrG6UZjNPrLb1eiJ3zsQuEd6iD/XfeyLrl3sjY8=; b=AwKjFNv9abCQdai3erC0JPCQwAE61MMUOZTZ5rhDLDLSXGuMIdLTMYB3SoR+k1ELpuNGSV 3o5mvekAEApL4wK2Su5IZxsRy4qCupq/grh7i7l/yO2ntgB3VN1ggj1oZEvAWrqWPkCMbi L8NaxMlfBs7MvEa0kmZ4k5ksXji7JVsSQ7sVOz3U1H1cTvcEv6HPVGEHhONRYy1BeqDZHg Cb9eZyAEdnj4to6KputtHSpO8ckiaIFjf361uucX9b3TUYJxFCLbm2v0H1Mc7KpI3Ycazf gfc/HLvGVOQvs1ArKpk6UyO/UvQfOqrpBZBVDX9uX7Xo6JCXMJmCXpe1epMSYQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1666963842; a=rsa-sha256; cv=none; b=GMFFxe9jXmkgtM7pg2wtY208xBsJeHkwgYugiHshCyVfskv4aJaR9Uc50OWftsNb+mrVQA dn66ADRSL4tjBGOU0j19bMTv1Or9aOcaepxEv3o/c+mVwudI/5qP6NbfleXvTChEsuPgkH h+Uo1aavBTQHZeMrD4RN0A60gIAnyJEzab+hFKIH0hZrT81YTzQzac3cYXU31sRSf91dsH XdoCauJ8zDyToMBvKfxxZD4Z7NIISnIfY9W9ioZnmt9taNVco19bF6JbYMaRrXXduI4lTb Ba87MnI34+1xOf2OlZJ9a+T5mCrVG4GOGuvt8zB3dP5X52zgJH3YTHVJ5cE1Vw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=HthzjTrU; 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" X-Migadu-Spam-Score: -7.12 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=HthzjTrU; 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" X-Migadu-Queue-Id: 0614120539 X-Spam-Score: -7.12 X-Migadu-Scanner: scn0.migadu.com X-TUID: MRP3LbMfSLW1 Rudolf Adamkovi=C4=8D writes: >>> 1. ob-shell/error-output-after-success >>> >>> We seem to trash error output, such as warnings, on success. I >>> think we should not do this. Now, on the execution of "echo X >>> &>2", Org says "Code block produced no output." But that does >>> hold true. The block did produce output, just on the other output >>> stream, namely error output. > >> Trashing error output is expected by default. [...] I suggest you to >> read through [...] ob-shell follows the spec here. > > I get that ':results output' makes Org capture standard output, but not > error output, for its #+RESULTS. However, if you look at the test in > question, you will see that it expects error output in the *Org-Babel > Error Output* buffer, not in the #+RESULTS. We should not trash error > output; it belongs in the *Org-Babel Error Output* buffer. I do not think that it make sense to display that buffer when the code finishes successfully. I can see this kind of behaviour breaking/spamming automated scripts or export---code working in the past may throw error output into unsuspecting users. >>> 3. ob-shell/exit-codes >>> >>> Should we add a newline after the exit code message? > >> Done. > > I updated the tests and now every string needs a final newline, which > does not seem correct. If we let the tests guide our design, all > becomes clear. Buffers that use the 'compilation-mode' never append > data on re-execution. Instead, they clear the buffer. > > Thus, we should > > 1. undo this change and instead > 2. call 'org-babel-eval-wipe-error-buffer' before execution. I do not think that it is a good idea. Code block execution may involve a whole chain of blocks when expanding references. If we wipe the error buffer and multiple blocks are failing, some errors may go unnoticed by the user. --=20 Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at