Skip to content


Choose a tag to compare
@Stewori Stewori released this 02 Apr 01:04
· 256 commits to master since this release

JyNI 2.7-alpha.2.1 is an intermediate release to demonstrate JyNI's new Tkinter capabilities.
Main improvements over alpha.2 are support for heap types and the introduction of a JyNI-GIL (global interpreter lock) to mimic CPython's GIL behaviour.

JyNI's "GIL" is not really global since it is scoped on native code (i.e. there can always be multiple threads in Java, but there can only be one thread in native extension-code at the same time, unless one uses Py_BEGIN_ALLOW_THREADS-macro). It is always acquired when a thread enters JyNI's native part and released when it enters Java code again. This way we aim to keep Jython-code free from multithreading regressions (Jython has no GIL because it uses Java's threading architecture), while native extensions get familiar GIL-induced behaviour in their native code.

Further built-in types are now supported: PyFunction, PyCode and (partly) PyCell. Additionally there were significant improvements for the support of PyType (these came with the support for heap-types).

JyNI alpha 2.1 was developed with the explicit goal to support Tkinter. It was tested with basic Tkinter code and the priority of bug-fixing was focused on the C-API needed by Tkinter. Nevertheless this resulted in numerous bug fixes giving benefit also to every other native extension.

The state of native garbage collection did not change since the last release (I promised GC support for alpha.3. This is why this release is called alpha.2.1 rather than alpha.3 ;-) ). So the advice from the last release is still relevant:
JyNI should not be used for more than demonstration purposes, since it would potentially leak a massive amount of memory if an extension crucially relies on garbage collection.

JyNI alpha 2.1 has been tested with

  • Jython 2.7 beta 1
  • Jython 2.7 beta 2 (pre-release)


  • Linux Mint Debian edition (LMDE) (32 bit and 64 bit)
  • Linux Mint 13 (64 bit)

If you compiled it for another distribution, please consider to report your experience to If you are using a distribution not listed above, we would also appreciate
any feedback, whether you got the binaries working or what error you received if any.