I have two python blocks. If I execute blockA
, then execute blockB
, it works fine. How can I only execute blockB
without manually executing blockA
? I am thinking add a :var from
blockA` but it does not work:
#+name blockA
#+begin_src python :session :results output
def funcA():
print("funcA")
return
#+end_src
#+RESULTS:
#+name blockB
#+begin_src python :session :results output :var x=blockA
def funcB():
funcA()
print("funcB")
return
funcB()
#+end_src