From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id wKr1F87JWGQcrgAASxT56A (envelope-from ) for ; Mon, 08 May 2023 12:07:10 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id 4CabF87JWGRJWAEAauVa8A (envelope-from ) for ; Mon, 08 May 2023 12:07:10 +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 EBBAE14201 for ; Mon, 8 May 2023 12:07:09 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pvxkm-00047k-EE; Mon, 08 May 2023 06:06:00 -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 1pvxkk-00047M-2C for emacs-orgmode@gnu.org; Mon, 08 May 2023 06:05:58 -0400 Received: from mout-p-103.mailbox.org ([2001:67c:2050:0:465::103]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1pvxkh-0004hi-Uw for emacs-orgmode@gnu.org; Mon, 08 May 2023 06:05:57 -0400 Received: from smtp2.mailbox.org (smtp2.mailbox.org [IPv6:2001:67c:2050:b231:465::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-103.mailbox.org (Postfix) with ESMTPS id 4QFH3n3bJzz9sjs; Mon, 8 May 2023 12:05:41 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kraus.my; s=MBO0001; t=1683540341; h=from:from: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; bh=8q8JDCl0OmfSHxkIgr6jbfrA11447Mf0S6n1pPnXqgw=; b=dwGneh1mwRiPCtw5xxoMBHPeJJ2UEfFwvZK5NUJZ9mCD+iXgn8oxmFqYIA2gfiv4bqVH7l hEu4moD3plX6C4+LVb44zd77+G7VVoGkO3wdY1NWXwTnOcLDtjgdoMJS0IovQLLD+/KyfG YiOAKWSmOyVVlgcD8aarlkZ5OJwYfPx0nNQGgSIBcFbi797n3mY5qX2OjX/jEpIabhIOb1 hAb0xOTa6IXqZjbAMEm9icRJ7XE3V0Vr7gp9yB6OQ6l39UJL71EXOgHjN8ZsjYcaM4e5Z+ u9Ct3h0wbf9YR2d0DBBGK4BVtFahN1ZfzjLjYx3nYe59oaOs0omHgyesR7Rq7Q== References: <87cz3eas4n.fsf@localhost> From: Daniel Kraus To: Ag Cc: Ihor Radchenko , emacs-orgmode@gnu.org Subject: Re: [BUG] Tangling of clojure code blocks is broken [9.7 (9.7-??-0807107 @ /Users/ag/.emacs.d/.local/straight/build-30.0.50/org/)] Date: Mon, 08 May 2023 12:05:10 +0200 In-reply-to: Message-ID: <87lehzb0k1.fsf@kraus.my> MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 4QFH3n3bJzz9sjs Received-SPF: pass client-ip=2001:67c:2050:0:465::103; envelope-from=daniel@kraus.my; helo=mout-p-103.mailbox.org X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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_LOW=-0.7, 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 ARC-Seal: i=1; s=key1; d=yhetil.org; t=1683540430; a=rsa-sha256; cv=none; b=bZOwEhFT1AYjsmc7RVlBnxy4J0lAdlMc3HDfl0ED2rljMweCEqZdtciHp5jMhDD1kHCc5R og3L0h9r7F9ZHno5uwp2JCd6ow5vhZwUmU2bMuLywed3B2NLok8SI9GftdPyRf8l5WldfW QZ3lco4eLgoABkyyPNg+9blkzs9CGI2EKgHzVMfAQYxOZHVx/n2qVFoPrXthqdbZQdZpSp 1h5Uj8rcIUsdKGPcnuEQyPMij1akNLwgRYwEqxyauksOAHhDU3+2bd1DFqFsOXrp9blpqR jivKUAiVg206zblaFRNM4F4nM0iZNvACjYVx3Oq9MBpYNEK87boz+UlnQ//LRA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=kraus.my header.s=MBO0001 header.b=dwGneh1m; dmarc=none; 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=1683540430; 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=8q8JDCl0OmfSHxkIgr6jbfrA11447Mf0S6n1pPnXqgw=; b=XOxaIcX0hHQtWG2YZugqMGQAREmiewivVWvmn5ohelO5dqLFcjhC4bRrWG1mrtbIMcT0v6 ppVFYXtEXvnl15/dqLXFd+RQkhZt2YmMRhn+uBt1HevbG9lLQSh9ey4bkmn7IlaZkeohqa 9K2fr4IaCoZ7ZRDf/EIx3+r/6Upd63ZZgUnpIRTQVy78goVWzkHidZXDP4xDo4Mzmk5CZV DgBSUfBJQSLhesr5NKfktC5h7uyHK02OMNEiZ7ir8neIvFisQ0tkZ6rdycpeVHtF5sn2pS pcWMTdEG4Eq9aWfFltoMCGgnK65Trp941VwzSynSMWWZGquCYzypEf92uw7QcQ== X-Migadu-Spam-Score: -2.21 X-Spam-Score: -2.21 X-Migadu-Queue-Id: EBBAE14201 X-Migadu-Scanner: scn0.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=kraus.my header.s=MBO0001 header.b=dwGneh1m; dmarc=none; 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-TUID: mnmyDJ57GC3L Hi! Ag writes: > Setting :results output header makes it work as expected. Without it - > it's as I described, wrapped. I can reproduce the bug. The problem is that or :results value (/the default) I only want the result of the last expression and I do that `binding` of stdout to surpress all other output. But I guess during tangle this should just be ignored? Is there a simple way to find out if `org-babel-execute:clojure` is executed or tangled? If it should be ignored on tangle, what about the :var defines. We recently discussed this for ob-scheme where there was a problem with the `let` wrapper. Is it ok or expected that a the tangled code is wrapped in a let block? Should I change it to a global `def`? Thanks for the bug report. PS, a minimal repo is minimal-org-clj.el: #+BEGIN_SRC emacs-lisp ;;; Minimal setup to load latest `org-mode'. ;; Activate debugging. (setq debug-on-error t debug-on-signal nil debug-on-quit nil) ;; Add latest Org mode to load path. (add-to-list 'load-path (expand-file-name "/home/daniel/.emacs.d/lib/org/lisp")) (org-babel-do-load-languages 'org-babel-load-languages '((clojure . t))) #+END_SRC /usr/bin/emacs -Q -l minimal-org-clj.el And then tangle something like: #+begin_src clojure :backend babashka :tangle foo.clj {:foo :bar} #+end_src Cheers, Daniel