From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric S Fraga Subject: Re: Re: [Babel] Handling of errors when using Ledger Date: Fri, 26 Nov 2010 08:34:15 +0000 Message-ID: <871v68eb5k.fsf@pinto.chemeng.ucl.ac.uk> References: <877hhudxor.fsf@mundaneum.com> <87sk0inmys.fsf@stats.ox.ac.uk> <807hhnfaix.fsf@mundaneum.com> <87mxqiv7q3.wl%ucecesf@ucl.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from [140.186.70.92] (port=56535 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PLtln-0001LE-Tp for emacs-orgmode@gnu.org; Fri, 26 Nov 2010 03:35:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PLtlB-0002En-6w for emacs-orgmode@gnu.org; Fri, 26 Nov 2010 03:35:02 -0500 Received: from vscani-d.ucl.ac.uk ([144.82.108.132]:61342) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PLtlB-0002DV-0M for emacs-orgmode@gnu.org; Fri, 26 Nov 2010 03:34:25 -0500 In-Reply-To: (Dan's message of "Thu, 25 Nov 2010 16:32:49 +0000 (UTC)") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Dan Cc: emacs-orgmode@gnu.org Dan writes: [...] > This patch should make ob-ledger use the common org-babel error mechanism. It is > in branch ledger of the main repo. However, I'm not yet a ledger user. Could > someone test it? Unfortunately, it doesn't work at all [1] for a very simple reason: you have removed the -f option which specifies the file that ledger should read. Ledger does not interpret a file argument directly but needs the -f option, as in: ledger -f file.ledger Note the second line in the concatenated list of strings below: [...] > - (with-output-to-string > - (shell-command (concat "ledger" > - " -f " (org-babel-process-file-name in-file) > - " " cmdline > - " > " (org-babel-process-file-name out-file)))) I am not sure how you pass this option with the much shorter code you have written: > + (org-babel-eval > + (concat org-babel-ledger-command " " (cdr (assoc :cmdline params))) > + body)) I hope this makes sense? Footnotes: [1] actually, what does work very nicely indeed is that error messages are reported perfectly!! So thank you very much for this. -- : Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 23.2.1 : using Org-mode version 7.3 (release_7.3.99.g9db0.dirty)