From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Wagle Subject: Re: Babel more verbose? Date: Tue, 2 Sep 2014 10:01:33 -0500 Message-ID: References: <878um2dqdw.fsf@alphaville.bos.redhat.com> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a11c37e1a2ce59705021665fb Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:53144) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XOpab-0003kI-Ic for emacs-orgmode@gnu.org; Tue, 02 Sep 2014 11:01:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XOpaR-0007JS-R8 for emacs-orgmode@gnu.org; Tue, 02 Sep 2014 11:01:45 -0400 Received: from mail-lb0-x22e.google.com ([2a00:1450:4010:c04::22e]:58697) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XOpaR-0007JD-EV for emacs-orgmode@gnu.org; Tue, 02 Sep 2014 11:01:35 -0400 Received: by mail-lb0-f174.google.com with SMTP id p9so7724319lbv.19 for ; Tue, 02 Sep 2014 08:01:33 -0700 (PDT) In-Reply-To: <878um2dqdw.fsf@alphaville.bos.redhat.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org --001a11c37e1a2ce59705021665fb Content-Type: text/plain; charset=UTF-8 It sounds like perhaps the issue is code blocks with a long run-time that may or may not fail or hang in some way? If that's the case, the solution is probably simply breaking up your code blocks into smaller bits of code so that you more easily follow what's happening. If the code is emacs-lisp, it's easy enough to put (message ...) calls entering and leaving the code blocks. On Tue, Sep 2, 2014 at 9:54 AM, Nick Dokos wrote: > John Kitchin writes: > > > Try this: > > > > #+BEGIN_SRC emacs-lisp > > (defadvice org-babel-execute-src-block (around progress nil activate) > > "create a buffer indicating what is running" > > (let ((code-block (org-element-property :name (org-element-at-point))) > > (cb (current-buffer))) > > (split-window-below) > > (other-window 1) > > (switch-to-buffer "*My Babel*") > > (insert (format "Running %s" code-block)) > > (other-window 1) > > ad-do-it > > (kill-buffer "*My Babel*") > > (delete-other-windows))) > > #+END_SRC > > > > It will mess with your windows a bit, but it does what you want I think. > > > > Wouldn't a (message (format "Running %s" code-block)) be enough? > That would avoid all the window munging. > > > > > Gary Oberbrunner writes: > > > >> I have an org-mode babel program/document that takes about half an > >> hour to run (end result is a LaTeX or HTML doc with figures). It's a > >> mix of SQL and python. (The SQL is the slow part.) I'd really like it > >> if org-mode could tell me, while it's running, which named block it's > >> processing. Is there anything like that available? An option perhaps? > > -- > Nick > > > --001a11c37e1a2ce59705021665fb Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
It sounds like perhaps the issue is code blocks = with a long run-time that may or may not fail or hang in some way?

=
If that's the case, the solution is probably simply breaking up your code= =20 blocks into smaller bits of code so that you more easily follow what's= =20 happening.

If the code is emacs-lisp, it's easy enough to put (message .= ..) calls entering and leaving the code blocks.


On Tue, Sep 2, 2014 at 9:54 AM, Ni= ck Dokos <ndokos@gmail.com> wrote:
John Kitchin <jkitchin@andrew.cmu.edu> writes:

> Try this:
>
> #+BEGIN_SRC emacs-lisp
> (defadvice org-babel-execute-src-block (around progress nil activate)<= br> >=C2=A0 =C2=A0"create a buffer indicating what is running"
>=C2=A0 =C2=A0(let ((code-block (org-element-property :name (org-element= -at-point)))
>=C2=A0 =C2=A0 =C2=A0 =C2=A0(cb (current-buffer)))
>=C2=A0 =C2=A0 =C2=A0(split-window-below)
>=C2=A0 =C2=A0 =C2=A0(other-window 1)
>=C2=A0 =C2=A0 =C2=A0(switch-to-buffer "*My Babel*")
>=C2=A0 =C2=A0 =C2=A0(insert (format "Running %s" code-block))=
>=C2=A0 =C2=A0 =C2=A0(other-window 1)
>=C2=A0 =C2=A0 =C2=A0ad-do-it
>=C2=A0 =C2=A0 =C2=A0(kill-buffer "*My Babel*")
>=C2=A0 =C2=A0 =C2=A0(delete-other-windows)))
> #+END_SRC
>
> It will mess with your windows a bit, but it does what you want I thin= k.
>

Wouldn't a (message (format "Running %s" code-block)) b= e enough?
That would avoid all the window munging.

>
> Gary Oberbrunner <garyo@ob= erbrunner.com> writes:
>
>> I have an org-mode babel program/document that takes about half an=
>> hour to run (end result is a LaTeX or HTML doc with figures). It&#= 39;s a
>> mix of SQL and python. (The SQL is the slow part.) I'd really = like it
>> if org-mode could tell me, while it's running, which named blo= ck it's
>> processing. Is there anything like that available? An option perha= ps?

--
Nick



--001a11c37e1a2ce59705021665fb--