Thank you for your input. I did think writting the Java bytecode translator
for PyPy before. I even checked out the pypy code and studied it. However,
from what I saw, PyPy is not production ready right now. Going to PyPy seem=
a little bit early for Jython right now.
I believe Jython's power comes from the combination of the Python language
and Java platform (libraries). If we can align Jython with agile Java
development closer, we can win huge mindshare in Java community. Here are
the features I want to see in Jython in the short time peoriod.
1. Has the new Python language feature such as method decoration. We can
defer the library related update later. The point is we don't really have t=
keep 100% compatible with Python. We just need the core language feature.
2. Can leverage the recent JDK change.
3. Integrate with Spring, Hibernate, JSF and other Java frameworks better.
Jython should be great on simplifying configuration (including depency
injection), testing, deployment, xml handling and other areas.
By improving the above three areas, I am pretty sure Jython can easily win
minshare in Fortune 500.
Just my 2 cents.
On 4/3/06, Samuele Pedroni <pedronis@...> wrote:
> Laurent Ploix wrote:
> > Hi Yan,
> > My own feeling is that translating from source (python) to source (java=
> > is a simpler approach, even if it is not the most powerful.
> is not simple at all, especially if the translation is used to generate
> a re-implementation of Jython.
> Notice that PyPy contains most of the technology needed to do RPython
> (a statically typeable subset of Python) to Java/Java bytecode
> The hard parts of this are done in a generic way for possible
> oo oritented targets. What is needed is "just" a backend. I expect
> writing such a thing to take some effort, but OTOH working on source
> to java translation for the purpose of getting a Jython
> re-implementation would be a rather pointless task. Writing a backend
> hard parts would be taming code size issues, and dealing with complex
> object graphs of constants. And tuning speed.
> Jythonc works because Jython contains a python runtime in java,
> which is what jythonc leans on. Of course You could not use such a
> technology to get a python runtime in java itself.
> > I think that
> > it is much easier to debug the translator when its output is java. But =
> > agree this is not the "best" approach in terms of performance /
> > But anyway, why should we care about generating byte-code if the java
> > compiler does it for us ?
> > Bye,
> > On 4/3/06, *Yan Weng* < wengyan@... <mailto:wengyan@...>>
> > Hi Laurent,
> > I guess we can't avoid "python 2 java" translator anyway. The
> > current Jythonc approach is just a source to source translator. If
> > we want a true "compiler", we have to translate the Jython AST to
> > java byte code.
> > BTW, I feel deployment and compiler are two relative weak areas of
> > Jython. But that may just be my personal feeling.
> > Best regards,
> > Yan
> > On 4/3/06, * Laurent Ploix* <laurent.ploix@...
> > <mailto:laurent.ploix@...>> wrote:
> > Hi,
> > Jython and Pypy is interesting, but here are some clarification=
> > (correct me if I'm wrong).
> > Writing Jython with Pypy would _not_ mean writing Jython in
> > Jython. Here is what that woud be :
> > Pypy projects contains :
> > - A python tp <other language> translator (C, for instance)
> > - A python interpreter, written in python
> > ...and the first python code that you want to translate in
> > <other language> is the python interpreter itself.
> > ...so you have a python interpreter (witten in python but
> > translated to <other language>) which runs your python code.
> > So, you may want to create a "python 2 java " translator. That
> > woud enable your python interpreter (written in python) to be
> > translated in Java, then this "java" python interpreter woud be
> > able to execute python code. (By the way, there are funny peopl=
> > that just try to interpret... the interpreter again... to
> > interpret python code, life is so funny !)
> > But it would not be "java-integrated" as Jython is, not without
> > a lot of work.
> > I personnaly think pypy is the right very long term approach,
> > but I think the current Jython approach is the right one on the
> > short term. The main point is that the Pypy approach enables yo=
> > to have a single python code for your interpreter, whatever the
> > targeted language (where it will be translated). Modifying the
> > interpreter behaviour becomes much easier. And the integration
> > with the targeted language becomes an isolated problem for each
> > language (which does not mean it is not a BIG issue anyway).
> > But working on a "python 2 java" translator would be complex,
> > not to mention the java integration !
> > 2 cents, again,
> > -----Message d'origine-----
> > De : jython-users-admin@...
> > <mailto:jython-users-admin@...>
> > [mailto:jython-users-admin@...
> > <mailto:jython-users-admin@...>] De la part d=
> > Leo User
> > Envoy=E9 : jeudi 30 mars 2006 17:45
> > =C0 : jython-dev@...
> > <mailto:jython-dev@...>;
> > jython-users@...
> > <mailto:jython-users@...>
> > Objet : [Jython-users] What are the implications of Jython goin=
> > PyPy?
> > howdy,
> > I just thought Id toss this out in the open since Ive
> > seen some talk about Jython becoming implemented like
> > PyPy. First off, I don't know much about PyPy but
> > from the sounds of it, its about implementing Python
> > in itself. I guess having Jython do the same thing is
> > to have Jython be implemented in itself. So this
> > comes to my big question:
> > What would going in that direction mean for tools
> > built on top of Jython.
> > Ive got 2 classes of apps in mind:
> > 1. Those that just use Jython as Jython. jyleo, for
> > example.
> > 2. Those that build using the Jython classes. jyleo's
> > JythonShell is an example here. Its pure Java and
> > uses alot of Jython's Java classes to acheive its
> > integration.
> > Im surmising a goal of going PyPy would be to make #1
> > class apps work fine. But what are the implications
> > of #2? Does my valuable code suddenly become a thing
> > that can't jump into the future? Granted there will
> > probably be work between jython version to jython
> > version to have it work. I had to do some recoding to
> > get it to work from jython 2.1 to jython 2.2.
> > What about other Java apps that embed Jython in
> > themselves and do like the JythonShell does and uses
> > Jython's Java classes?
> > thanks!
> > leouser
> > __________________________________________________
> > Do You Yahoo!?
> > Tired of spam? Yahoo! Mail has the best spam protection around
> > http://mail.yahoo.com
> > -------------------------------------------------------
> > This SF.Net email is sponsored by xPML, a groundbreaking
> > scripting language
> > that extends applications into web and mobile media. Attend the
> > live webcast
> > and join the prime developer group breaking into this new codin=
> > territory!
> > <
> > _______________________________________________
> > Jython-users mailing list
> > Jython-users@...
> > <mailto:Jython-users@...>
> > https://lists.sourceforge.net/lists/listinfo/jython-users
> > <https://lists.sourceforge.net/lists/listinfo/jython-users>