emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [BUG] ob-python :results value pp does not working


From: Christopher M. Miles
Subject: Re: [BUG] ob-python :results value pp does not working
Date: Fri, 31 Dec 2021 10:33:27 +0800
User-agent: mu4e 1.7.0; emacs 29.0.50

Thanks Jack. Confirmed works. This might need to mentioned in Org manual and in 
ob-python.el source
code with comment. WDYT?

Jack Kamm <jackkamm@gmail.com> writes:

> For non-session Python blocks, you need to use "return" on the value, as
> if you are in a function.
>
> The following works for me:
>
> #+begin_src python :results value pp
>   dic = {'key1': 1, 'b': 2}
>   return dic
> #+end_src
>
> #+RESULTS:
> : {'b': 2, 'key1': 1}


-- 
[ stardiviner ]
       I try to make every word tell the meaning that I want to express.

       Blog: https://stardiviner.github.io/
       IRC(freenode): stardiviner, Matrix: stardiviner
       GPG: F09F650D7D674819892591401B5DF1C95AE89AC3

Attachment: signature.asc
Description: PGP signature


reply via email to

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