Message3993

Author cgroves
Recipients cgroves, dmbaggett, fwierzbicki
Date 2008-12-30.08:22:22
SpamBayes Score 9.448456e-08
Marked as misclassified No
Message-id <1230625342.5.0.113318927611.issue1181@psf.upfronthosting.co.za>
In-reply-to
Content
I implemented this as a PEP 302 hook in r5816 on trunk. It uses
getResourceAsStream on the classloader on sys or on the context class
loader if that one doesn't find anything. Instead of using a jar: prefix
to find things, it picks up on __pyclasspath__ entries in sys.path to
decide what level to import from in the classpath, like the
__classpath__ entry used by the Java importer. I think this should do
what you want and get your applets going, but I'd appreciate it if you'd
check.

By default __pyclasspath__ is added to sys.path, so .py and $py.class
files directly on the classpath will be loaded.  If you have them in a
Lib directory in your jar, you'll want to replace __pyclasspath__ with
__pyclasspath__/Lib.
History
Date User Action Args
2008-12-30 08:22:22cgrovessetmessageid: <1230625342.5.0.113318927611.issue1181@psf.upfronthosting.co.za>
2008-12-30 08:22:22cgrovessetrecipients: + cgroves, fwierzbicki, dmbaggett
2008-12-30 08:22:22cgroveslinkissue1181 messages
2008-12-30 08:22:22cgrovescreate