From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.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 CKoDBLG9XmMXHwAAbAwnHQ (envelope-from ) for ; Sun, 30 Oct 2022 19:08:49 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id uEfkArG9XmNTwwAAG6o9tA (envelope-from ) for ; Sun, 30 Oct 2022 19:08:49 +0100 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 8DD2D1E46B for ; Sun, 30 Oct 2022 19:08:48 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1opCis-00012A-5R; Sun, 30 Oct 2022 14:07:50 -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 1opCiq-0000lb-31 for emacs-orgmode@gnu.org; Sun, 30 Oct 2022 14:07:48 -0400 Received: from mx1.polytechnique.org ([129.104.30.34]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opCin-0003kz-NQ for emacs-orgmode@gnu.org; Sun, 30 Oct 2022 14:07:47 -0400 Received: from set (cbg35-2-78-242-14-140.fbx.proxad.net [78.242.14.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ssl.polytechnique.org (Postfix) with ESMTPSA id DA2B156461C for ; Sun, 30 Oct 2022 19:07:39 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=polytechnique.org; s=svoboda; t=1667153259; bh=tDNr6Eyw3NBAQ+6gDFn6ID8XWNPBareFRInrwZki1f4=; h=From:To:Subject:Date:Message-ID; b=TsGf4C4JIJyB5foMpD40RsfUzB6IHFYyODz9AdElp2tYYg43CwBWgfzlIw0K7QZM2 A+Pb4BZuKXvmIO/T3RDbIuzeYkeBsORopizeYFzeBCoqXCHyTccF/zaqLVJUeX6mjr S99tpJlkqgUOdOp6hVWjH3NvqBPXnuX+ts516vig= From: alan.schmitt@polytechnique.org To: emacs-orgmode@gnu.org Subject: org-sbe recent changes? Date: Sun, 30 Oct 2022 19:07:21 +0100 Message-ID: <87h6zldw2u.fsf@m4x.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-AV-Checked: ClamAV using ClamSMTP at svoboda.polytechnique.org (Sun Oct 30 19:07:40 2022 +0100 (CET)) X-Org-Mail: alan.schmitt.1995@polytechnique.org Received-SPF: pass client-ip=129.104.30.34; envelope-from=SRS0=IdDO=27=polytechnique.org=alan.schmitt@bounces.m4x.org; helo=mx1.polytechnique.org X-Spam_score_int: -40 X-Spam_score: -4.1 X-Spam_bar: ---- X-Spam_report: (-4.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.248, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_PASS=-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.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=1667153328; 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=TcyhlPIIUKlkYNUPhQRLTW//NQaV2yLsSP7PqyyuifY=; b=odHh8RUoZNmsl0VICUmEvRkrmX3aRabUz17B20KvT1RQnBAcRfIWEo3mcZjzdZs3iE9T6i zF4w4rEVI9G2+c0/Ed9xMwrAmfSdxsvQhZhOez96qKiGlv01q1lYdBBGeYq7Drw89IR7nK S7V/T0Z9XYHpQwqj9Sh2pE59cNx7K7jsxhsGkZYaT/VSXD7XPyNQsxew+Myi1UEMSfqToG f410knEz1efRrxoJMRVECU+KWR52eWMMb15LfxlzLO10yFg8+9nfX9Lc0F9dQ9zxJ9T66J k1LsgGc408+Flh0hVccBZY5qZUhmEA1gA3WEA9rVvMixMoOZHhK811b2jnNshg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1667153328; a=rsa-sha256; cv=none; b=gz9dNvdyBPczePc4PJ3mXAbKZyLjdojAZwTQCB1Z3AOi3/ZnKWJ7YY53qaFBv1nVzbO65J rmfSCjitA291SWPEliYnk3/9W/uBAG9by77h0Wqqjr+r4GAoo51nSPBkANohqip3e7noQV lVf8hm8kivLQRu5Tudv5MQ5YtfbUpWbFsRyvrzhQX0Hpywkci82mMYn67Wx/P2WhfRrqST jjhZ+cWhQloUXtNND0veub+DcS7Lp20z/Ot912RtG3OyGSLmoUolLpkC8fI2SxiC25LSNO uxbR6bbBw+f+ssdgEAZnzZEAM4eGSAr+X5dUV+A93z5hN/W8h8IV7Dg2AQk3wg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=polytechnique.org header.s=svoboda header.b=TsGf4C4J; 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-Migadu-Spam-Score: -6.75 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=polytechnique.org header.s=svoboda header.b=TsGf4C4J; 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-Migadu-Queue-Id: 8DD2D1E46B X-Spam-Score: -6.75 X-Migadu-Scanner: scn1.migadu.com X-TUID: mDCZ4tWBrBpy --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hello, I=E2=80=99ve been using ledger and an org-mode table to track my finances f= or a long time, and today it broke: when I evaluate a table macro, I get an #ERROR instead of the computed value. The code I=E2=80=99m using is still the one from here: https://alan.petitepomme.net/tips/ledger_and_org.html Basically I define a function like this (I added the message part for debug= ging): #+name: call_ledger #+begin_src emacs-lisp :var lcmd=3D"bal" :var bucket=3D"Quotidien" :var pre= fix=3D"Expenses:" :var period=3D() (let* ((name (org-trim bucket)) (bname (concat "'^" prefix name "'")) (ledger "ledger -f ~/Documents/Org/mescomptes.ledger") (parg (when period (concat " -p '" period "'"))) (cutcmd "tail -1 | cut -d ' ' -f 2") (cmd (concat ledger " -J " parg " " lcmd " " bname " | " cutcmd)) (res (org-trim (shell-command-to-string cmd)))) (message res) (if (equal res "") 0 res)) #+end_src Then I call it in a table that looks like this (removing a lot of stuff for privacy reasons): | Bucket | Planned | Remaining | |--------------------------------+---------+-----------+ | Achat Maison | 1000 | #ERROR | |--------------------------------+---------+-----------+ | Total | 1000 | #ERROR | #+TBLFM: @2$3..@>>$3=3D'(org-sbe call_ledger (bucket $$1) (prefix "\"Bucket= :Expenses:\"")) It used to work, but now I get an #ERROR. The strange thing is that the correct value is printed with the message call. Did something change recently regarding org-sbe and table? How can I find out what the value is causing the #ERROR to be printed? Thanks, Alan --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQFTBAEBCAA9FiEE6lXof/BsSVW56ZmGBA0KO07S5ccFAmNevVkfHGFsYW4uc2No bWl0dEBwb2x5dGVjaG5pcXVlLm9yZwAKCRAEDQo7TtLlxwQKB/0ZgROQUMUUqNhi enpank2E2K1hlmt1fqpr76VrDC0HHW3/ZUns/lVi7S4AP/osEC5RjTH2beRuXVeb Rx1Cw56EGyTOqIlnd2RXQQFplLoGPeook8f7q2dnKTm/sZQDor2yUcq2C4SGmqSC JTBh/ZlCmwkraK+Vl/U3UQvmRaQTz1rMchdXPY8bOmqTe9G0nGNsBzcqBaQHr1Xf nPX/iwZetqmgXAiL+DUR3MMqayASo1FJBI8/VI0aEh9v1eaQnNGF2BpS6e0xOlt2 TInn5FWSwnBiA7SErO2SbqGwwlvK+79imz5m95znLJRZqKoR7+ZYCIYbso39iS3a 8Y8RisLe =8Xsm -----END PGP SIGNATURE----- --=-=-=--