Right in time for Jython 2.7.1 we are proud to announce the release of JyNI v2.7-alpha.3, which is quite a milestone. Packed with new features and improvements it finally masters to bridge Jython's and CPython's garbage collection mechanisms. A lot of work went into this release, including an entire Google Summer of Code project (see http://gsoc2015-jyni.blogspot.de). Take a look at the main milestones:
- garbage collection for native objects is implemented, plus a mechanism to (unit-)test it
(see upcoming paper "Garbage Collection in JyNI – How to bridge Mark/Sweep and Reference Counting GC in Proc. of the 8th. European Conference on Python in Science (EuroSciPy 2015)" for further reading on this topic)
- JyNI is now also workable (and tested) on Mac OS-X (the Tkinter demo currently fails, see #4)
- the ctypes extension is supported (many original ctypes unittests currently fail though, but mostly due to secondary issues; the core functionality is working, a demo-script is provided)
The road to these milestones is paved with bugfixes, extended API support and several design improvements. To name a few:
- The referencing scheme was cleaned up and now follows clear rules in line with JNI requirements.
- Support for weak references and corresponding builtin types was achieved.
- The handling of subtypes was improved, which incorporated massive work in typeobject.c
- ThreadState API was improved - e.g. the PyGILState_xxx method family is now supported in a Jython consistent way. Threads are attached or detached to/from the JVM properly (c.f. JNI methods AttachCurrentThread and DetachCurrentThread). This incorporated a redesign of how JyNI handles SystemState, ThreadState and the GIL.
- It is now possible to use JyNI from pure Java-code, which was originally hindered by several bugs. The upcoming EuroSciPy 2015 paper about JyNI features a rich example of this (see JyNI.TestTk.java).
- The work on JyNI also triggered improvements on Jython, e.g. PyDictionary and PyStringMap were unified under a common abstract class and most work on the gc module is grounded in JyNI development.
JyNI v2.7-alpha.3 requires Jython 2.7.1. You can currently use it with Jython 2.7.1 beta3, available on Frank's blog: http://fwierzbicki.blogspot.de/2016/02/jython-271-beta3-released.html
JyNI v2.7-alpha.3 was tested with Java 7 and 8 on
- Linux Mint Debian Edition (LMDE) (32 bit and 64 bit)
- Linux Mint 17 (64 bit)
- Mac OS-X (10.10 and 10.11)