Thanks for you quick response.
I'v checked the Lib/xml/* dirs and all the class files seems to be there, nicely cached.
So from that POV everything is OK, and the 'make_parser' command should  return fast and swift since
recompilation is not carried out.
The strange think is that the cacheing, with regards to SAX, only seem to work "inside" an invocation of the Jython shell. Not between
invocations of the shell, even if the classes are not recompiled (I'v checked that).
-----Original Message-----
From: Kevin Butler [mailto:kbutler@campuspipeline.com]
Sent: den 31 januari 2002 01:29
To: Örjan Reinholdsen
Subject: Re: [Jython-dev] Jython and SAX

Örjan Reinholdsen wrote:
> Greetings,
> When I run the following script with jython
> from xml import sax
> xmlParser = sax.make_parser()
> it takes somewhat 15 sec. to complete. Subsequent calls to
> 'make_parser' are blazing fast (cached I guess). Is this
> resonable or is there something I could do to shorten this
> rather anoying wait? Trying the same trick with (C) Python
> takes only 1-2 secs.

If you have write access to the Lib/xml/* subdirectories, the first time you did it, it should have cached .class files to accelerate loading the files in future invocations of the interpreter.

The first time I imported it, it took ~15 seconds, subsequent calls were fast. 
Exit, restart jython, import, make_parser took ~2 seconds.
Exit, remove all .class files under xml, and it takes 15 again...

> Another thing, is there a way to use some of the
> state-of-the-art XML parsers written in Java (like Crimson)
> with the Jython SAX API's (without reinventning the wheel)?

Don't know. :-)