From mboxrd@z Thu Jan 1 00:00:00 1970 From: "numbchild@gmail.com" Subject: ob-clojure.el does not evaluate org-mode clojure src block Date: Mon, 20 Feb 2017 20:41:39 +0800 Message-ID: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a1140caae8a67bc0548f59799 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:50258) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cfnIC-00018L-Ms for emacs-orgmode@gnu.org; Mon, 20 Feb 2017 07:42:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cfnIB-0008VM-D8 for emacs-orgmode@gnu.org; Mon, 20 Feb 2017 07:42:12 -0500 Received: from mail-it0-x22e.google.com ([2607:f8b0:4001:c0b::22e]:34867) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cfnIB-0008V9-6y for emacs-orgmode@gnu.org; Mon, 20 Feb 2017 07:42:11 -0500 Received: by mail-it0-x22e.google.com with SMTP id 203so71069364ith.0 for ; Mon, 20 Feb 2017 04:42:10 -0800 (PST) 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" To: Org-mode --001a1140caae8a67bc0548f59799 Content-Type: text/plain; charset=UTF-8 ``` #+BEGIN_SRC clojure :session (def kk "stardiviner") #+END_SRC ``` Press =[C-c C-c]= to evaluate this. Then check out =kk= in CIDER REPL buffer. That's why my problem happens: https://emacs.stackexchange.com/questions/30849/how-to-generate-inline-plot-result-for-ob-clojure Also I did some simple edebug on ob-clojure.el: =ob-clojure.el::org-babel-execute:clojure= ``` #+BEGIN_SRC emacs-lisp (nrepl-dict-get (nrepl-sync-request:eval "(print \"hello, world!\")" (cider-current-connection) (cider-current-session)) ;; key: "output", "status" "output") #+END_SRC ``` ``` #+RESULTS: #+BEGIN_EXAMPLE (dict "status" ("namespace-not-found" "done" "error" "done" "state" "state") "id" "8" "session" "7dcda490-01d9-4411-a05b-804a4f8663b6" "changed-namespaces" (dict) "repl-type" "cljclj") #+END_EXAMPLE ``` You can see the request evaluate result is error. [stardiviner] GPG key ID: 47C32433 IRC(freeenode): stardiviner Twitter: @numbchild Key fingerprint = 9BAA 92BC CDDD B9EF 3B36 CB99 B8C4 B8E5 47C3 2433 Blog: http://stardiviner.github.io/ --001a1140caae8a67bc0548f59799 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
= ```
=C2=A0 =C2=A0 =C2=A0 #+BE= GIN_SRC clojure :session
=C2=A0 =C2=A0 =C2=A0 (def kk "stardivin= er")
=C2=A0 =C2=A0 =C2=A0 #+END_SRC
```

<= /div>
P= ress =3D[C-c C-c]=3D to evaluate this. Then check out =3Dkk=3D in CIDER REP= L buffer.

That's why my problem happens:
<= div class=3D"gmail_default">

Also I did some simple edebug on ob-clojure.el:

=3Dob-clojure.el::org-babel-execute:clojure= =3D

```
=C2=A0 =C2=A0 =C2=A0 #+BEGIN_SRC em= acs-lisp
=C2=A0 =C2=A0 =C2=A0 (nrepl-dict= -get
=C2=A0 =C2=A0 =C2=A0 =C2=A0(nrepl-sy= nc-request:eval "(print \"hello, world!\")" (cider-curr= ent-connection) (cider-current-session))
= =C2=A0 =C2=A0 =C2=A0 =C2=A0;; key: "output", "status"
=C2=A0 =C2=A0 =C2=A0 =C2=A0"output&qu= ot;)
=C2=A0 =C2=A0 =C2=A0 #+END_SRC
=
```

```
=C2=A0= =C2=A0 =C2=A0 =C2=A0#+RESULTS:=C2=A0
=C2= =A0 =C2=A0 =C2=A0 =C2=A0#+BEGIN_EXAMPLE
= =C2=A0 =C2=A0 =C2=A0 =C2=A0(dict "status"
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0("namespace= -not-found" "done" "error" "done" "= state" "state")
=C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0"id" "8" "se= ssion" "7dcda490-01d9-4411-a05b-804a4f8663b6" "changed-= namespaces"
=C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0(dict)
=C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0"repl-type" "cljclj&qu= ot;)
=C2=A0 =C2=A0 =C2=A0 =C2=A0#+END_EXA= MPLE
```

You can see the request evaluat= e result is error.


[stardiviner= ]=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 <Hack this= world!>=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 GPG key ID: 47C32433
IRC(freee= node): stardiviner =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 Twitter:=C2=A0= @numbchild
Key fingerprint =3D 9BAA 92BC CDDD B9EF 3B36=C2=A0 CB99 B8C4= B8E5 47C3 2433
Blog: http://stardiviner.github.io/
--001a1140caae8a67bc0548f59799--