emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] graphviz dot block export and evaluate


From: Thomas S. Dye
Subject: Re: [O] graphviz dot block export and evaluate
Date: Fri, 28 Sep 2012 07:14:15 -1000

Dmitri Makarov <address@hidden> writes:

> Hi all,
>
> Has anyone successfully exported and evaluated src blocks with
> graphviz dot code?
> I'm trying to export this block
>
>    #+BEGIN_SRC dot :export both
>      digraph G {
>        A -> B
>      }
>    #+END_SRC
>
> and I'm getting the error
>
> org-babel-exp processing...
> executing Dot code block...
> file-name-extension: Wrong type argument: stringp, nil
>
> How do you debug such problems?
>
> Regards,
>
> Dmitri

Aloha Dmitri,

Currently, you can debug such problems by looking at the source code of
ob-dot.el.  Or, by asking the list, as you did.

Your example is lacking a :file header argument.  dot source code blocks
produce graphics files and babel leaves it to the user to name the
output file.  The file-name-extension function is looking for the value
of the :file header argument, so that it can configure the call to dot.
It is expecting to see a string, but gets nil because the header
argument is absent.

Also, the correct keyword is :exports, with a final "s".

You can find an example of dot code use here:
http://www.jstatsoft.org/v46/i03

hth,
Tom
-- 
Thomas S. Dye
http://www.tsdye.com



reply via email to

[Prev in Thread] Current Thread [Next in Thread]