From: tsd@tsdye.com (Thomas S. Dye)
To: Dmitri Makarov <dmakarv@gmail.com>
Cc: "emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: Re: graphviz dot block export and evaluate
Date: Fri, 28 Sep 2012 07:14:15 -1000 [thread overview]
Message-ID: <m1k3vekr2w.fsf@tsdye.com> (raw)
In-Reply-To: <C62ACE57-E48C-4F93-B585-CC75BE6363C7@gmail.com> (Dmitri Makarov's message of "Fri, 28 Sep 2012 18:51:56 +0200")
Dmitri Makarov <dmakarv@gmail.com> 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
next prev parent reply other threads:[~2012-09-28 17:14 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-28 16:51 graphviz dot block export and evaluate Dmitri Makarov
2012-09-28 17:07 ` Bastien
2012-09-28 17:14 ` Thomas S. Dye [this message]
2012-09-28 17:27 ` Dmitri Makarov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m1k3vekr2w.fsf@tsdye.com \
--to=tsd@tsdye.com \
--cc=dmakarv@gmail.com \
--cc=emacs-orgmode@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.