Just to be clear here:
Jython can certainly call Python libraries, because Jython is simply an
implementation of the Python language for the Java platform. For the 2.5
release, our major focus has been compatibility with the 2.5 version of the
Python language and specifically with the CPython reference implementation.
For previous releases, like Jython 2.2, I would suspect most Python 2.2 code
would also run fine, it's just now we are trying to run larger, more
ambitious code in Python as a community. Consider Django, Twisted, Pylons,
In my experience, most interesting libraries are written in pure Python.
Often it's in pure Python to simplify support on Windows, or even for other
implementations like ours or IronPython.
Now granted, there are libraries that don't run on Jython. These libraries
are written to use the C extension API. The most significant ones I know of
are PIL and NumPy. There are also others that optionally use C extensions to
increase performance; we should run on them, but perhaps without the desired
performance, until we have similar Java extensions in place.
Other libraries use ctypes, which has started to replace the use of the C
extension API in most code. The good news is that we will almost certainly
have ctypes support in our 2.5.1 release, using work from PyPy and JRuby.
Then there are libraries that rely on specific functionality, like os.fork
or advanced signal handling. JRuby has had some progress on the former, and
we share development on the underlying jna-posix library, regardless, these
are Python libraries that would not be portable to non-Unix systems.
On Tue, May 19, 2009 at 7:43 AM, Nick Rothwell <nick@...> wrote:
> On 19 May 2009, at 12:57, kilon wrote:
> > Jython CANNOT use python libraries.
> Jython can use libraries written purely in Python. (For example, the
> pickle machinery works fine.) Many of these ship with the Jython
> distribution. Jython can't use libraries that call into C.
> -- N.
> Nick Rothwell / Cassiel.com Limited
> Crystal Reports - New Free Runtime and 30 Day Trial
> Check out the new simplified licensing option that enables
> unlimited royalty-free distribution of the report engine
> for externally facing server and web deployment.
> Jython-users mailing list