jpython casting to abstract java class
Douglas du Boulay
ddb at crystal.uwa.edu.au
Fri Jun 30 04:16:59 EDT 2000
Well thanks, for providing that example of yours Chris.
It appears that I was struck by the dreaded system path versus
classpath problem again.
My directory hierarchy was
<pre>
top ---- A -------parser
\ *.py src *.java src
\ (parser module)
\----B
working
directory
</pre>
I had CLASSPATH = A while working in directory B but
calling a *.py source file from A which imported some
components of my java "parser" package from the A/parser directory.
For some reason in jpython1.1 that must have got loaded via the
system path, and not via the CLASSPATH as it did for jpython1.0.3.
Moving the parser directory somewhere else and sticking the new
directory containing it on the CLASSPATH, fixes the problem.
I thought I was immune from this problem by working in directory
B, but apparently I was wrong.
doug
P.S. for the record, the discrepancy arose because the
PyInstance.javaProxy object was not considered to be an instance of
the underlying abstract java class I was subclassing.
Maybe someone will fix that oneday?
More information about the Python-list
mailing list