jupyter
jupyter copied to clipboard
:file header fails to create the link to the result
When I try to plot using matplotlib using org source block as follows:
#+begin_src jupyter-python :file tangle/tmp.png
import matplotlib.pyplot as plt
\\ some code here \\
...
plt.show()
#+end_src
the result block looks like this:
#+RESULTS:
[[tangle/tmp.png]]
in which file: is missing. It should be like this:
#+RESULTS:
[[file:tangle/tmp.png]]
:END:
It was used to be like this. But after I changed my system to Fedora and installed new doom emacs, it began to act weirdly. Any help will be appreciated. Thanks!
It’s a bit late, but I found a workaround. You need to write a complete or relative path in your :file argument because in that case you don’t need the "file:" prefix. For example, in your case:
#+begin_src jupyter-python :file ./tangle/tmp.png
import matplotlib.pyplot as plt
\\ some code here \\
...
plt.show()
#+end_src
Hope this helps.