You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(6) |
Nov
(8) |
Dec
(51) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(105) |
Feb
(93) |
Mar
(194) |
Apr
(145) |
May
(100) |
Jun
(111) |
Jul
(117) |
Aug
(126) |
Sep
(233) |
Oct
(138) |
Nov
(164) |
Dec
(109) |
2002 |
Jan
(216) |
Feb
(175) |
Mar
(216) |
Apr
(194) |
May
(157) |
Jun
(140) |
Jul
(158) |
Aug
(73) |
Sep
(105) |
Oct
(164) |
Nov
(104) |
Dec
(95) |
2003 |
Jan
(72) |
Feb
(69) |
Mar
(81) |
Apr
(151) |
May
(101) |
Jun
(139) |
Jul
(99) |
Aug
(118) |
Sep
(115) |
Oct
(151) |
Nov
(161) |
Dec
(102) |
2004 |
Jan
(120) |
Feb
(175) |
Mar
(106) |
Apr
(111) |
May
(54) |
Jun
(78) |
Jul
(76) |
Aug
(105) |
Sep
(94) |
Oct
(143) |
Nov
(75) |
Dec
(85) |
2005 |
Jan
(99) |
Feb
(77) |
Mar
(164) |
Apr
(97) |
May
(79) |
Jun
(57) |
Jul
(65) |
Aug
(102) |
Sep
(95) |
Oct
(129) |
Nov
(123) |
Dec
(52) |
2006 |
Jan
(48) |
Feb
(99) |
Mar
(90) |
Apr
(51) |
May
(81) |
Jun
(136) |
Jul
(56) |
Aug
(109) |
Sep
(50) |
Oct
(44) |
Nov
(74) |
Dec
(75) |
2007 |
Jan
(92) |
Feb
(137) |
Mar
(93) |
Apr
(79) |
May
(52) |
Jun
(74) |
Jul
(143) |
Aug
(175) |
Sep
(154) |
Oct
(137) |
Nov
(88) |
Dec
(90) |
2008 |
Jan
(58) |
Feb
(113) |
Mar
(167) |
Apr
(88) |
May
(105) |
Jun
(37) |
Jul
(87) |
Aug
(72) |
Sep
(56) |
Oct
(41) |
Nov
(102) |
Dec
(70) |
2009 |
Jan
(115) |
Feb
(113) |
Mar
(126) |
Apr
(58) |
May
(125) |
Jun
(45) |
Jul
(90) |
Aug
(125) |
Sep
(84) |
Oct
(61) |
Nov
(111) |
Dec
(61) |
2010 |
Jan
(85) |
Feb
(86) |
Mar
(130) |
Apr
(58) |
May
(57) |
Jun
(32) |
Jul
(25) |
Aug
(50) |
Sep
(41) |
Oct
(65) |
Nov
(63) |
Dec
(24) |
2011 |
Jan
(43) |
Feb
(31) |
Mar
(28) |
Apr
(68) |
May
(53) |
Jun
(42) |
Jul
(58) |
Aug
(26) |
Sep
(51) |
Oct
(76) |
Nov
(60) |
Dec
(9) |
2012 |
Jan
(16) |
Feb
(32) |
Mar
(32) |
Apr
(39) |
May
(16) |
Jun
(19) |
Jul
(3) |
Aug
(11) |
Sep
(35) |
Oct
(47) |
Nov
(28) |
Dec
(18) |
2013 |
Jan
(18) |
Feb
(36) |
Mar
(10) |
Apr
(7) |
May
(7) |
Jun
(27) |
Jul
(17) |
Aug
(35) |
Sep
(19) |
Oct
(31) |
Nov
(8) |
Dec
(22) |
2014 |
Jan
(5) |
Feb
(11) |
Mar
(18) |
Apr
(23) |
May
(26) |
Jun
(14) |
Jul
(18) |
Aug
(26) |
Sep
(20) |
Oct
(48) |
Nov
(13) |
Dec
(9) |
2015 |
Jan
(9) |
Feb
(15) |
Mar
(25) |
Apr
(10) |
May
(26) |
Jun
(6) |
Jul
(13) |
Aug
(5) |
Sep
(14) |
Oct
(36) |
Nov
(24) |
Dec
(18) |
2016 |
Jan
(24) |
Feb
(11) |
Mar
(1) |
Apr
(6) |
May
(7) |
Jun
(3) |
Jul
(9) |
Aug
(15) |
Sep
(22) |
Oct
(5) |
Nov
(5) |
Dec
(2) |
2017 |
Jan
(20) |
Feb
(4) |
Mar
(4) |
Apr
(1) |
May
(5) |
Jun
(7) |
Jul
(14) |
Aug
(9) |
Sep
(18) |
Oct
(2) |
Nov
(3) |
Dec
(3) |
2018 |
Jan
(7) |
Feb
(6) |
Mar
(1) |
Apr
(2) |
May
|
Jun
|
Jul
(1) |
Aug
(18) |
Sep
(8) |
Oct
(9) |
Nov
(4) |
Dec
(6) |
2019 |
Jan
(5) |
Feb
|
Mar
(2) |
Apr
(4) |
May
(6) |
Jun
(8) |
Jul
(11) |
Aug
(10) |
Sep
(6) |
Oct
|
Nov
(1) |
Dec
|
2020 |
Jan
(8) |
Feb
(3) |
Mar
(1) |
Apr
(4) |
May
(1) |
Jun
(1) |
Jul
|
Aug
|
Sep
(1) |
Oct
(5) |
Nov
(2) |
Dec
(1) |
2021 |
Jan
|
Feb
|
Mar
(5) |
Apr
(2) |
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2022 |
Jan
|
Feb
(2) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
(7) |
Aug
(1) |
Sep
(1) |
Oct
|
Nov
|
Dec
|
2023 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(3) |
Jun
(5) |
Jul
(15) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2024 |
Jan
|
Feb
(1) |
Mar
|
Apr
(2) |
May
|
Jun
(5) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2025 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Boudewijn R. <bo...@re...> - 2000-12-04 13:15:02
|
I've got the console working - even if I still have to hack Actions.py to be able to switch back to strong security, so now I've started to integrate my application interface in the console. However, this is a first for me, and I'm not an experienced Java developer, so I wanted to ask you all to look at my solution, and give criticism (like: this is a hack! It's unsupported! Don't do it! ;-). What I've done is this: All functionality to the core application goes via an adapter. There's already a Swing gui, so that was easy. I've added an extra parameter to the constructor of the console, where I put the adapter object: class Console (Object): def __init__(self, adapter=None, adapterName=""): "@sig public Console(Object adapter, java.lang.String adapterName)" self.locals = {} if adapter!=None: self.locals[adapterName]=adapter I've given the signature Object, so I can reuse the console for other adapters - this is the point where I'm not sure. I can access the interface from the Jython prompt, that's true. From Java I call it like this: Console console=new Console(managementGuiAdapter, "managementAdapter"); JScrollPane pane=new JScrollPane(console.getTextPane()); console.write("Tryllian AFC 1.5 Habitat Management Console\n" + "Uses Jython technology.\n" ,"output"); console.capturePythonOutput(); console.getTextPane().requestFocus(); console.newInput(); getContentPane().add(pane); And everything seems nice - but is it, really? Boudewijn Rempt | http://www.valdyas.org |
From: <bc...@wo...> - 2000-12-03 13:02:13
|
On Sat, 2 Dec 2000 19:42:21 -0500, you wrote: >I follow the instructions in jythonc.html, and modules appear missing. I >can find a PyProxy.java, but no class file. (help) The corresponding class file is located inside the jython.jar file. There is no need to extract the jar file, but it must be included in your classpath. >Jython works great as a python interpreter, though. > >Thanks, Eric > > >D:\programs\jython-2.0a1\Demo\javaclasses> jythonc Graph.py >processing Graph > >D:\programs\jython-2.0a1\Demo\javaclasses>cd jpywork/ > >D:\programs\jython-2.0a1\Demo\javaclasses\jpywork> java Graph >java.lang.NoClassDefFoundError: org/python/core/PyProxy > at java.lang.ClassLoader.defineClass0(Native Method) >Exception in thread "main" Try instead to to use: java -classpath D:\programs\jython-2.0a1\jython.jar Graph You can also try the --jar and --all options on jythonc. That will create a new jar file which include all the required org.python.* classes. regards, finn |
From: Eric F. <eri...@ny...> - 2000-12-03 00:39:46
|
I follow the instructions in jythonc.html, and modules appear missing. I can find a PyProxy.java, but no class file. (help) Jython works great as a python interpreter, though. Thanks, Eric D:\programs\jython-2.0a1\Demo\javaclasses> jythonc Graph.py jythonc Graph.py processing Graph Required packages: java.awt Creating adapters: java.awt.event.ActionListener used in Graph Creating .java files: Graph module Graph extends java.awt.Canvas Compiling .java to .class... Compiling with args: ['d:\\programs\\java\\bin\\javac', '-classpath', 'd:\\programs\\jython-2.0a1\\jython.jar;.;d:/programs/java/jre/lib/;C:\\Prog ram Files\\Exceed.nt\\hcljrcsv.zip;C:\\Program Files\\Exceed.nt;.\\jpywork;;d:\\programs\\jython-2.0a1\\Tools\\jythonc;.;d: \\programs\\jython-2.0a1\\Lib', '.\\jpywork\\Graph.java'] 0 Note: .\jpywork\Graph.java uses or overrides a deprecated API. Note: Recompile with -deprecation for details. D:\programs\jython-2.0a1\Demo\javaclasses>cd jpywork/ cd jpywork/ D:\programs\jython-2.0a1\Demo\javaclasses\jpywork> java Graph java Graph java.lang.NoClassDefFoundError: org/python/core/PyProxy at java.lang.ClassLoader.defineClass0(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:486) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:111) at java.net.URLClassLoader.defineClass(URLClassLoader.java:248) at java.net.URLClassLoader.access$100(URLClassLoader.java:56) at java.net.URLClassLoader$1.run(URLClassLoader.java:195) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:297) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:286) at java.lang.ClassLoader.loadClass(ClassLoader.java:253) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:313) Exception in thread "main" D:\programs\jython-2.0a1\Demo\javaclasses\jpywork> --- Eric Freudenthal // Courant Institute // New York University office: 212-998-3345 // cell:917-279-6208 715 Broadway, Room 1011, New York, NY 10003 cell pager: eri...@fr... (100 char limit) |
From: Samuele P. <pe...@in...> - 2000-12-01 20:34:17
|
Hi. One problem we encounter is that for the classes in Action.py jythonc does not really compile proxies, so these are created at runtime. The line: from pawt import swing in Action.py should be changed in something more explicit like from javax import swing so proxies are created. I have not tried if the resulting Console class works. I can imagine that the new context of not-runtime created proxies could possibly avoid the problem. From your stack trace I deduce that under your security settings code in the Console jar can call code that creates classloaders without creating security problems. This is not true for runtime created proxies because they have no permissions. regards, Samuele Pedroni. ----- Original Message ----- From: Boudewijn Rempt <bo...@re...> To: <jyt...@so...> Sent: Friday, December 01, 2000 3:58 PM Subject: [Jython-users] Embedding a python console in java - security problems > Well, thanks to all the help I've succeeded in getting the > Console.py compiled in to a jarfile, and I can call the code from my > application. However, the app uses the java.security features, and it > appears that the Jython BytecodeLoader classloader is wreaking havoc in > the subtle scheme of security. > > First we got this: > > onal> > <additional-text>Exception is java.security.AccessControlException, message is access denied (java.lang.RuntimePermission > createClassLoader)</additional-text> > <additional-trace>java.security.AccessControlException: access denied (java.lang.RuntimePermission createClassLoader) > at java.security.AccessControlContext.checkPermission(AccessControlContext.java :272) > at java.security.AccessController.checkPermission(AccessController.java:399) > at java.lang.SecurityManager.checkPermission(SecurityManager.java:545) > at com.tryllian.are.security.SecurityManager.checkPermission(SecurityManager.ja va:188) > at java.lang.SecurityManager.checkCreateClassLoader(SecurityManager.java:610) > at java.lang.ClassLoader.<init>(ClassLoader.java:234) > at org.python.core.BytecodeLoader.<init>(BytecodeLoader.java:8) > at org.python.core.BytecodeLoader.makeCode(BytecodeLoader.java:148) > at org.python.core.Py.compile(Py.java:1449) > at org.python.modules.codeop.compile_command(codeop.java:23) > at org.python.modules.code.compile_command(code.java:8) > at java.lang.reflect.Method.invoke(Native Method) > at org.python.core.PyReflectedFunction.__call__(PyReflectedFunction.java:158) > at org.python.core.PyReflectedFunction.__call__(PyReflectedFunction.java:166) > at org.python.core.PyObject.__call__(PyObject.java:272) > at org.python.pyconsole.Console$_PyInner.handleLine$20(Console.java:426) > at org.python.pyconsole.Console$_PyInner.call_function(Console.java:222) > at org.python.core.PyTableCode.call(PyTableCode.java:155) > at org.python.core.PyTableCode.call(PyTableCode.java:222) > at org.python.core.PyFunction.__call__(PyFunction.java:99) > at org.python.core.PyInstance.invoke(PyInstance.java:267) > at org.python.pyconsole.Console$_PyInner.enter$13(Console.java:350) > at org.python.pyconsole.Console$_PyInner.call_function(Console.java:208) > at org.python.core.PyTableCode.call(PyTableCode.java:155) > at org.python.core.PyTableCode.call(PyTableCode.java:353) > at org.python.core.PyTableCode.call(PyTableCode.java:258) > at org.python.core.PyFunction.__call__(PyFunction.java:110) > at org.python.core.PyMethod.__call__(PyMethod.java:83) > at org.python.core.PyObject.__call__(PyObject.java:260) > at org.python.core.PyInstance.invoke(PyInstance.java:256) > at org.python.pyconsole.Action$_PyInner.actionPerformed$2(Action.java:90) > at org.python.pyconsole.Action$_PyInner.call_function(Action.java:46) > at org.python.core.PyTableCode.call(PyTableCode.java:155) > at org.python.core.PyTableCode.call(PyTableCode.java:353) > at org.python.core.PyTableCode.call(PyTableCode.java:258) > at org.python.core.PyFunction.__call__(PyFunction.java:110) > at org.python.core.PyMethod.__call__(PyMethod.java:83) > at org.python.core.PyObject.__call__(PyObject.java:250) > at org.python.core.PyObject._jcallexc(PyObject.java:2017) > at org.python.core.PyObject._jcall(PyObject.java:2049) > at org.python.proxies.Action$Action$0.actionPerformed(Unknown Source) > at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1702) > at javax.swing.JComponent.processKeyBinding(JComponent.java:2156) > at javax.swing.JComponent.processKeyBindings(JComponent.java:2182) > at javax.swing.JComponent.processKeyEvent(JComponent.java:2119) > at javax.swing.JEditorPane.processKeyEvent(JEditorPane.java:1159) > at java.awt.Component.processEvent(Component.java:3555) > at java.awt.Container.processEvent(Container.java:1164) > at java.awt.Component.dispatchEventImpl(Component.java:2595) > at java.awt.Container.dispatchEventImpl(Container.java:1213) > at java.awt.Component.dispatchEvent(Component.java:2499) > at java.awt.LightweightDispatcher.processKeyEvent(Container.java:2155) > at java.awt.LightweightDispatcher.dispatchEvent(Container.java:2135) > at java.awt.Container.dispatchEventImpl(Container.java:1200) > at java.awt.Window.dispatchEventImpl(Window.java:912) > at java.awt.Component.dispatchEvent(Component.java:2499) > at java.awt.EventQueue.dispatchEvent(EventQueue.java:319) > at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:103) > at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93) > at java.awt.EventDispatchThread.run(EventDispatchThread.java:84) > </additional-trace> > </additional></info> > > Our local security expert traced this to > > Class: class org.python.proxies.Action$Action$0 > ClassLoader: org.python.core.BytecodeLoader@61dadb > CodeSource: (null <no certificates>) > Permissions: java.security.Permissions@24c414 ( > (java.util.PropertyPermission java.vendor read) > (java.util.PropertyPermission java.specification.version read) > (java.util.PropertyPermission line.separator read) > (java.util.PropertyPermission java.class.version read) > (java.util.PropertyPermission java.specification.name read) > (java.util.PropertyPermission java.vendor.url read) > (java.util.PropertyPermission java.vm.version read) > (java.util.PropertyPermission os.name read) > (java.util.PropertyPermission os.arch read) > (java.util.PropertyPermission os.version read) > (java.util.PropertyPermission java.version read) > (java.util.PropertyPermission java.vm.specification.version read) > (java.util.PropertyPermission java.vm.specification.name read) > (java.util.PropertyPermission java.specification.vendor read) > (java.util.PropertyPermission java.vm.vendor read) > (java.util.PropertyPermission file.separator read) > (java.util.PropertyPermission path.separator read) > (java.util.PropertyPermission java.vm.name read) > (java.util.PropertyPermission java.vm.specification.vendor read) > ) > > Which appears not to come from any jarfile, which means that it can't > be signed - which means that the secureClassLoader chokes on it. We couldn't > find the origin of proxies.Action, anyway. > > I'm going to try whether deriving the BytecodeLoader from a SecureClassLoader > makes any difference, but I feel that that's a rather long shot. > > Boudewijn Rempt | http://www.valdyas.org > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > http://lists.sourceforge.net/mailman/listinfo/jython-users > |
From: <bc...@wo...> - 2000-12-01 17:18:02
|
[Boudewijn Rempt] >Well, thanks to all the help I've succeeded in getting the >Console.py compiled in to a jarfile, and I can call the code from my >application. However, the app uses the java.security features, and it >appears that the Jython BytecodeLoader classloader is wreaking havoc in >the subtle scheme of security. >... >Class: class org.python.proxies.Action$Action$0 > ClassLoader: org.python.core.BytecodeLoader@61dadb > CodeSource: (null <no certificates>) > Permissions: java.security.Permissions@24c414 ( >Which appears not to come from any jarfile, which means that it can't >be signed - which means that the secureClassLoader chokes on it. We couldn't >find the origin of proxies.Action, anyway. The org.python.proxies.Action$Action$0 class is a dynamicly generated class, created because the static jythonc compiler failed to detect that the Action class in Action.py is subclassing a java class. Try changing the Action.py file like this: --- Action.py.org Wed Feb 24 15:45:27 1999 +++ Action.py Fri Dec 01 17:53:37 2000 @@ -1,5 +1,5 @@ # I don't really like the design of this one... -from pawt import swing +from javax import swing class Action(swing.AbstractAction): The "pawt" module is a clever and dynamic way to detect the name of the swing package, much to clever for jythonc. When jythonc failes to create a proxy for swing.AbstractAction at compile time, jython will instead create it at runtime. regards, finn |
From: Boudewijn R. <bo...@re...> - 2000-12-01 15:00:45
|
Well, thanks to all the help I've succeeded in getting the Console.py compiled in to a jarfile, and I can call the code from my application. However, the app uses the java.security features, and it appears that the Jython BytecodeLoader classloader is wreaking havoc in the subtle scheme of security. First we got this: onal> <additional-text>Exception is java.security.AccessControlException, message is access denied (java.lang.RuntimePermission createClassLoader)</additional-text> <additional-trace>java.security.AccessControlException: access denied (java.lang.RuntimePermission createClassLoader) at java.security.AccessControlContext.checkPermission(AccessControlContext.java:272) at java.security.AccessController.checkPermission(AccessController.java:399) at java.lang.SecurityManager.checkPermission(SecurityManager.java:545) at com.tryllian.are.security.SecurityManager.checkPermission(SecurityManager.java:188) at java.lang.SecurityManager.checkCreateClassLoader(SecurityManager.java:610) at java.lang.ClassLoader.<init>(ClassLoader.java:234) at org.python.core.BytecodeLoader.<init>(BytecodeLoader.java:8) at org.python.core.BytecodeLoader.makeCode(BytecodeLoader.java:148) at org.python.core.Py.compile(Py.java:1449) at org.python.modules.codeop.compile_command(codeop.java:23) at org.python.modules.code.compile_command(code.java:8) at java.lang.reflect.Method.invoke(Native Method) at org.python.core.PyReflectedFunction.__call__(PyReflectedFunction.java:158) at org.python.core.PyReflectedFunction.__call__(PyReflectedFunction.java:166) at org.python.core.PyObject.__call__(PyObject.java:272) at org.python.pyconsole.Console$_PyInner.handleLine$20(Console.java:426) at org.python.pyconsole.Console$_PyInner.call_function(Console.java:222) at org.python.core.PyTableCode.call(PyTableCode.java:155) at org.python.core.PyTableCode.call(PyTableCode.java:222) at org.python.core.PyFunction.__call__(PyFunction.java:99) at org.python.core.PyInstance.invoke(PyInstance.java:267) at org.python.pyconsole.Console$_PyInner.enter$13(Console.java:350) at org.python.pyconsole.Console$_PyInner.call_function(Console.java:208) at org.python.core.PyTableCode.call(PyTableCode.java:155) at org.python.core.PyTableCode.call(PyTableCode.java:353) at org.python.core.PyTableCode.call(PyTableCode.java:258) at org.python.core.PyFunction.__call__(PyFunction.java:110) at org.python.core.PyMethod.__call__(PyMethod.java:83) at org.python.core.PyObject.__call__(PyObject.java:260) at org.python.core.PyInstance.invoke(PyInstance.java:256) at org.python.pyconsole.Action$_PyInner.actionPerformed$2(Action.java:90) at org.python.pyconsole.Action$_PyInner.call_function(Action.java:46) at org.python.core.PyTableCode.call(PyTableCode.java:155) at org.python.core.PyTableCode.call(PyTableCode.java:353) at org.python.core.PyTableCode.call(PyTableCode.java:258) at org.python.core.PyFunction.__call__(PyFunction.java:110) at org.python.core.PyMethod.__call__(PyMethod.java:83) at org.python.core.PyObject.__call__(PyObject.java:250) at org.python.core.PyObject._jcallexc(PyObject.java:2017) at org.python.core.PyObject._jcall(PyObject.java:2049) at org.python.proxies.Action$Action$0.actionPerformed(Unknown Source) at javax.swing.SwingUtilities.notifyAction(SwingUtilities.java:1702) at javax.swing.JComponent.processKeyBinding(JComponent.java:2156) at javax.swing.JComponent.processKeyBindings(JComponent.java:2182) at javax.swing.JComponent.processKeyEvent(JComponent.java:2119) at javax.swing.JEditorPane.processKeyEvent(JEditorPane.java:1159) at java.awt.Component.processEvent(Component.java:3555) at java.awt.Container.processEvent(Container.java:1164) at java.awt.Component.dispatchEventImpl(Component.java:2595) at java.awt.Container.dispatchEventImpl(Container.java:1213) at java.awt.Component.dispatchEvent(Component.java:2499) at java.awt.LightweightDispatcher.processKeyEvent(Container.java:2155) at java.awt.LightweightDispatcher.dispatchEvent(Container.java:2135) at java.awt.Container.dispatchEventImpl(Container.java:1200) at java.awt.Window.dispatchEventImpl(Window.java:912) at java.awt.Component.dispatchEvent(Component.java:2499) at java.awt.EventQueue.dispatchEvent(EventQueue.java:319) at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:103) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93) at java.awt.EventDispatchThread.run(EventDispatchThread.java:84) </additional-trace> </additional></info> Our local security expert traced this to Class: class org.python.proxies.Action$Action$0 ClassLoader: org.python.core.BytecodeLoader@61dadb CodeSource: (null <no certificates>) Permissions: java.security.Permissions@24c414 ( (java.util.PropertyPermission java.vendor read) (java.util.PropertyPermission java.specification.version read) (java.util.PropertyPermission line.separator read) (java.util.PropertyPermission java.class.version read) (java.util.PropertyPermission java.specification.name read) (java.util.PropertyPermission java.vendor.url read) (java.util.PropertyPermission java.vm.version read) (java.util.PropertyPermission os.name read) (java.util.PropertyPermission os.arch read) (java.util.PropertyPermission os.version read) (java.util.PropertyPermission java.version read) (java.util.PropertyPermission java.vm.specification.version read) (java.util.PropertyPermission java.vm.specification.name read) (java.util.PropertyPermission java.specification.vendor read) (java.util.PropertyPermission java.vm.vendor read) (java.util.PropertyPermission file.separator read) (java.util.PropertyPermission path.separator read) (java.util.PropertyPermission java.vm.name read) (java.util.PropertyPermission java.vm.specification.vendor read) ) Which appears not to come from any jarfile, which means that it can't be signed - which means that the secureClassLoader chokes on it. We couldn't find the origin of proxies.Action, anyway. I'm going to try whether deriving the BytecodeLoader from a SecureClassLoader makes any difference, but I feel that that's a rather long shot. Boudewijn Rempt | http://www.valdyas.org |
From: Boudewijn R. <bo...@re...> - 2000-12-01 11:10:46
|
On Fri, 1 Dec 2000, Finn Bock wrote: > The @sig only works on classes that subclass java, not for standard > python classes. So if you don't want the Console class to subclass > something else, just use java.lang.Object: <...> Thanks! I've got everything compiling and even running now - I've got a nice and clean pyconsole.jar that I can add to my companies projecs without having to explain exactly how I got that nice console... And thanks for the warning about the accessor functions. Boudewijn Rempt | http://www.valdyas.org |
From: <bc...@wo...> - 2000-12-01 08:09:57
|
[Boudewijn Rempt] >I've been hacking away at Console.py - I want to use it from >my java app. But no matter what I do, I don't get any >public methods. I've attached my version of Console.py. I want >to call it with something like: > > Console console=new Console(); > JScrollPane pane=new JScrollPane(console.getTextPane()); > console.capturePythonOutput(); > console.textpane.requestFocus(); > console.newInput(); > >Can anyone tell me what I'm doing wrong? The @sig only works on classes that subclass java, not for standard python classes. So if you don't want the Console class to subclass something else, just use java.lang.Object: @@ -18,7 +18,7 @@ from pawt import swing, colors from java.awt.event.KeyEvent import VK_UP, VK_DOWN from java.awt.event import ActionEvent -from java.lang import Thread, System +from java.lang import Thread, System, Object from code import compile_command import string, sys, re @@ -33,7 +33,7 @@ def write(self, text): self.console.write(text, self.stylename) -class Console: +class Console(Object): def __init__(self): "@sig public Console()" >I'm trying to embed the Demo/swing/console in my Java >application, and I was wondering whether I could get >the instance variables like textpane without creating >accessor functions. Is that at all possible? No. You have to add accessor functions [*]. And when you add accessor functions, these functions will also be called from the Console methods themselfs. Ie. the line: self.document = swing.text.DefaultStyledDocument(self.styles) will try to assign a new value to the bean property created by the existenceof the "getDocument()" method. If you also had a setDocument() method, the line above would have called that method. This often end up in an infinite recursion. To avoid that, you will have to rename the instance variable name to something else: self._document = swing.text.DefaultStyledDocument(self.styles) regards, finn [*] You can also use the Jython API. Then the textpane line becomes: //console.textpane.requestFocus(); Py.java2py(console).__getattr__("textpane").invoke("requestFocus"); |
From: Boudewijn R. <bo...@re...> - 2000-11-30 16:06:57
|
I've been hacking away at Console.py - I want to use it from my java app. But no matter what I do, I don't get any public methods. I've attached my version of Console.py. I want to call it with something like: Console console=new Console(); JScrollPane pane=new JScrollPane(console.getTextPane()); console.capturePythonOutput(); console.textpane.requestFocus(); console.newInput(); Can anyone tell me what I'm doing wrong? Boudewijn Rempt | http://www.valdyas.org |
From: Boudewijn R. <bo...@re...> - 2000-11-30 14:44:13
|
I'm trying to embed the Demo/swing/console in my Java application, and I was wondering whether I could get the instance variables like textpane without creating accessor functions. Is that at all possible? Boudewijn Rempt | http://www.valdyas.org |
From: Joey G. <joe...@mi...> - 2000-11-29 02:50:59
|
On Tue, 28 Nov 2000 13:23:58 +0800, irwan <ry...@tm...> wrote: ||| Below is i simple code that i've alredy write it but have an error ||| ||| #odbc.py ||| ||| from java.sql import * ||| [snip] ||| >>> from odbc import connection ||| >>>p=connection('Test','sa','password') ||| Traceback (innermost last): ||| File "<console>", line 1, in? ||| FIle "C:\jython\jython-2.0a1\odbc.py" line 5 in? ||| Name Error: Class You also need to import Class from java.lang. In a true Java program you get everything in java.lang imported for free. But In JPython (I really don't like the new name) you have to do it explicitly: from java.lang import * or, if you don't like bringing whole packages in: from java.lang import Class Joey -- -- Sun Certified Java2 Programmer -- Political Rants: www.joeygibson.com -- My Pocket Smalltalk Stuff: st.joeygibson.com -- -- "We thought about killin' him, but we kinda -- hated to go that far...." |
From: <bc...@wo...> - 2000-11-28 09:29:30
|
[irwan] >I've already download jython-2.0a1 and successfully installed to my computer. >I would like to make a databse connection using java sql module. Do you >have any reference that i can use it. The zxJDBC module from http://www.ziclix.com/ may be usefull to you. >Below is i simple code that i've alredy write it but have an error I made a few changes; now the program will at least try to open the Test data through odbc. I do not have such a database on my PC so I have not tested the program further than that. regards, finn from java.sql import * import java class connection(Driver): def __init__(self,url,username,password): java.lang.Class.forName("sun.jdbc.odbc.JdbcOdbcDriver") self.db=DriverManager.getConnection(url,username,password) self.st=self.db.createStatement() print "Database Connected" rs=st.executeQuery("select * from acount_t") try: if rs.next(): str='%s' % rs.getString(1) print str except: print "Error" self.st.close() self.db.close() p=connection('jdbc:odbc:Test','sa','password') |
From: irwan <ry...@tm...> - 2000-11-28 05:01:29
|
I've already download jython-2.0a1 and successfully installed to my computer. I would like to make a databse connection using java sql module. Do you have any reference that i can use it. Below is i simple code that i've alredy write it but have an error #odbc.py from java.sql import * class connection(Driver): def __init__(self,url,username,password): Class.forName("sun.jdbc.odbc.JdbcOdbcDriver") self.db=DriverManager.getConnection(url,username,password) self.st=self.db.createStatement() print "Database Connected" rs=st.executeQuery("select * from acount_t") try: if rs.next(): str='%s' % rs.getString(1) print str except: print "Error" self.st.close() self.db.close() >>> from odbc import connection >>>p=connection('Test','sa','password') Traceback (innermost last): File "<console>", line 1, in? FIle "C:\jython\jython-2.0a1\odbc.py" line 5 in? Name Error: Class |
From: <bc...@wo...> - 2000-11-26 19:20:59
|
Hello Jython and JPython users, Jython-2.0alpha1 is finally available. This early access release is governed by a patchwork license where each of the different parts of Jython are covered by their original license and the modifications done be the Jython-developers are release under a BSD like license. http://jython.sourceforge.net/index.html The free installer LiftOff is used to create the distribution. The jython-20a1.class must be executed as with JPython-1.1. The standard python modules are included in the installer. No further downloads are needed. I don't intend to announce this any more widely than these lists for now to keep the initial set of alpha testers relatively small. News (off the top of my head, will improve later): - List comprehension. - Extended call syntax. - Extended print statement - Augmented assignment. - Unicode support libraries and codecs. - sre unicode regular expression. Possible Problem Changes (but big wins in general): - Text files will pass data read and written through the default codecs for the JVM. Binary files will write only the lower eight bits of each unicode character. - The precedence of java loading have changed. Now the sys.path is searched for python modules before the CLASSPATH and sys.path is searched for java class and java packages. Take a look at the NEWS file for more information about the differences. http://jython.sourceforge.net/NEWS.html Bugs can be reported to the bug manager on SourceForge: http://sourceforge.net/bugs/?group_id=12867 Cheers, the jython-developers |
From: Mikael N. <pur...@te...> - 2000-11-19 04:35:49
|
subscribe |
From: <bc...@wo...> - 2000-11-15 13:20:05
|
Hi, We need some new graphics for jython. I have put up a webpage with the submissions so far. http://jython.sourceforge.net/graphics.html regards, finn |
From: <ba...@wo...> - 2000-10-24 02:07:18
|
>>>>> "FB" == Finn Bock <bc...@wo...> writes: FB> Maybe a new installer. A free one for instance. It would be FB> nice if everyone could create an installable .class file. I wonder if the free version of InstallAnywhere will do the trick? I last looked at it probably a year or more ago and it had some problems. It's not open source, but it is free. Does anybody know of any decent cross platform open source installers? -Barry |
From: <bc...@wo...> - 2000-10-23 13:08:18
|
[Kip Lehman] >Now that Jython is hosted on SourceForge, is there an ETA on when >the Jython package will be available for download? There is no estimate at this time. >I'm assuming that it'll come out as Jython 1.0 and will incorporate >all the functionality and features of JPython 1.1 along with Finn Bock's >last errata package. Is this correct? 1) The version would most likely be Jython-2.0: i:\>jython Jython 2.0 pre-alpha on java1.3.0 (JIT: null) Type "copyright", "credits" or "license" for more information. >>> IMO, this version number makes perfect sense considering that jpython-2.0 is fully compatible with all the new features in Python-2.0. 2) It will certainly contain all of the errata. All fixes in the errata have already been added to the CVS. There will never be a reason for choosing the errata over jython. 3) The CVS version already contain more fixes and features than the errata. Extended print and list comprehension to name two. There are still some things which I would like to see fixed before an alpha1 release: - Maybe a new installer. A free one for instance. It would be nice if everyone could create an installable .class file. - Small changes to the way classes are loaded. This is to fix the "can't coerce self" bug and remove some of the differences between java package and java dir packages. regards, finn |
From: Kip L. <ki...@am...> - 2000-10-23 12:26:57
|
Now that Jython is hosted on SourceForge, is there an ETA on when the Jython package will be available for download? I'm assuming that it'll come out as Jython 1.0 and will incorporate all the functionality and features of JPython 1.1 along with Finn Bock's last errata package. Is this correct? -- Kip ki...@am... |
From: Brian R. <br...@us...> - 2000-10-21 05:27:27
|
subscribe |
From: brad y. <byo...@ya...> - 2000-10-19 14:33:39
|
From: Chris A. <at...@nm...> - 2000-10-19 14:12:58
|