3

Is there an org-babel for the Jython (not Python, it must be Jython) programming language? I am especially interested in session based evaluation for Jython. I am considering writing my own ob-jython.el, but want to make sure this has not been tackled yet.

  • What features would you miss using ob-python with the jython interpreter instead of python? – T. Verron May 26 '15 at 14:35
  • @T.Verron How does one go about swapping out the Python interpreter? – Julien Chastang May 26 '15 at 14:50
  • @Drew, the tag should really say "jython" not "jpython". Thanks. – Julien Chastang May 26 '15 at 21:02
4

You can change the babel python interpreter to jython with:

(setq org-babel-python-command "jython")

  • This seems to work, at least partially. A Python (which is really Jython) Buffer/shell is created --similar to what happens with Python-- but it seems org has trouble communicating to the Jython process. The results are somewhat garbled though they do return in a somewhat readable state. Also I don't believe session based evaluations are working. I will continue to experiment, and let you know what I find. – Julien Chastang May 26 '15 at 18:38
  • Actually, I retract what I said earlier. Session mode does seem to work as long as you remember to stay in session mode with the :session source block argument. Moreover, the output seems to only be garbled with the first evaluation. Subsequent code blocks seem to look good. Great. Thanks @Jesse. – Julien Chastang May 26 '15 at 21:00
  • No problem. Happy to help :) – Jesse May 26 '15 at 22:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.