Index: test338.py =================================================================== --- test338.py (revision 2866) +++ test338.py (working copy) @@ -1,5 +1,7 @@ """ [ #480017 ] Proxy supers are loaded from syspath +Running test338j will throw a ClassCastException if a proxy's superclass is loaded +by the syspath classloader. """ import support @@ -8,6 +10,5 @@ support.compileJava("test338j1.java", classpath=".") support.compileJava("test338j.java", classpath=".") -#support.runJava("test338j", classpath=".") -raise support.TestWarning("Should (maybe) not fail.") +support.runJava("test338j", classpath=".") Index: test338j.java =================================================================== --- test338j.java (revision 2866) +++ test338j.java (working copy) @@ -11,11 +11,8 @@ public void run() { String brob = "test338m"; - PythonInterpreter interp = new PythonInterpreter(); - //Py.getSystemState().setClassLoader(this.getClass().getClassLoader()); interp.set("test338j1", test338j1.class); - //interp.exec("mod = __import__('" + brob + "')"); interp.execfile(brob + ".py"); interp.exec("cl = " + brob + "()"); Object newobj = interp.get("cl", Object.class); @@ -23,7 +20,6 @@ //System.out.println(newobj.getClass().getSuperclass().hashCode() + " " + test338j1.class.hashCode()); //System.out.println(newobj.getClass().getSuperclass().getClassLoader()); test338j1 boobj = (test338j1) newobj; - //System.out.println(boobj.getDescription()); } }