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: Robert W. B. <rb...@di...> - 2000-12-15 00:55:04
|
Hi Frank, On Fri, 15 Dec 2000, Frank Chen wrote: > Hi: > > In JPython, I met this problem too. I cannot compile a Java program > contained a class made out of JPython. > > If we just import "org.python.util.PythonInterpreter" in JSP's Java code, I > cannot imagine > where it can go far? > > If I want to save a file, make a search through the PythonInterpreter > object, it looks like very difficult?! > > > > > I have not been able to use jythonc compiled files with JSP. There > > were too many troubles loading the inner class. If I write a > > jython class foo with method whatever, either "foo$_PyInner.class not > > found in import" or "Method Whatever not found in class foo." This is > > confusing when the log shows the classpath used for the jsp- which > appears > > correct. I haven't had time to look into why this happens, mainly > because > > "import org.python.util.PythonInterpreter;" is so effective. > > > > However, it would be nice to just say jythonc foo.py and be done with it. > > > > Have others been through this? I didn't mean to import the PythonInterpreter in the JSP code. I actually was thinking about instances (no pun intended) where writing a java class that imports PythonInterpreter acts as the proxy for python files. In this case, import the java class in the JSP, initialize PythonInterpreter in the java class, then use the java class's interfaces to get at your python files. I hope this helps clarify. -Robert |
From: Frank C. <fr...@ms...> - 2000-12-14 22:40:35
|
Hi: In JPython, I met this problem too. I cannot compile a Java program contained a class made out of JPython. If we just import "org.python.util.PythonInterpreter" in JSP's Java code, I cannot imagine where it can go far? If I want to save a file, make a search through the PythonInterpreter object, it looks like very difficult?! > > I have not been able to use jythonc compiled files with JSP. There > were too many troubles loading the inner class. If I write a > jython class foo with method whatever, either "foo$_PyInner.class not > found in import" or "Method Whatever not found in class foo." This is > confusing when the log shows the classpath used for the jsp- which appears > correct. I haven't had time to look into why this happens, mainly because > "import org.python.util.PythonInterpreter;" is so effective. > > However, it would be nice to just say jythonc foo.py and be done with it. > > Have others been through this? > > Thanks, > Robert |
From: Anton G. <gl...@mi...> - 2000-12-14 07:05:22
|
Many thanks to the people who responded to my post. You helped clear up the situation with memory management and speed considerations a lot. Anton |
From: Robert W. B. <rb...@di...> - 2000-12-14 01:27:59
|
On Wed, 13 Dec 2000, cch wrote: > Hi: > > Is that possisble to use Jython with JSP? > > cch > I have not been able to use jythonc compiled files with JSP. There were too many troubles loading the inner class. If I write a jython class foo with method whatever, either "foo$_PyInner.class not found in import" or "Method Whatever not found in class foo." This is confusing when the log shows the classpath used for the jsp- which appears correct. I haven't had time to look into why this happens, mainly because "import org.python.util.PythonInterpreter;" is so effective. However, it would be nice to just say jythonc foo.py and be done with it. Have others been through this? Thanks, Robert |
From: Boudewijn R. <bo...@re...> - 2000-12-13 06:18:58
|
On Wed, 13 Dec 2000, Samuele Pedroni wrote: > Hi. > > > Isn't Samuele Pedroni's scratchpad an example of this? > > > > http://sourceforge.net/projects/jppad/ > > > > No, it's a standalone application. I guess not the good startpoint for > attaching a window > inside an existing application. > > VisAD JPythonEditor should be (I guess) such a thing: > > http://www.ssec.wisc.edu/~billh/visad.html#python ... > > regards, Samuele Pedroni. > I've used the example Pyconsole for this end - I needed to tweak it a bit to circumvent Java security, but in the end it was very doable. I'm currently trying to find a publisher interested in an article on the process, but basically, what you need to do is add a signature to everything in Pyconsole, make it a Java Object and pass it an object that contains your interface to your application. People on this list have been very helpful, so there are threads about it. I can send you the actual Python code, if you want. Boudewijn Rempt | http://www.valdyas.org |
From: Samuele P. <pe...@in...> - 2000-12-13 01:00:18
|
Hi. > Isn't Samuele Pedroni's scratchpad an example of this? > > http://sourceforge.net/projects/jppad/ > No, it's a standalone application. I guess not the good startpoint for attaching a window inside an existing application. VisAD JPythonEditor should be (I guess) such a thing: http://www.ssec.wisc.edu/~billh/visad.html#python ... regards, Samuele Pedroni. |
From: Adam B. <ada...@gb...> - 2000-12-12 22:53:17
|
Isn't Samuele Pedroni's scratchpad an example of this? http://sourceforge.net/projects/jppad/ > -----Original Message----- > From: James Bullard [SMTP:bu...@pe...] > Sent: Wednesday, December 13, 2000 3:03 AM > To: JPy...@py... > Subject: [JPython] embedding > > I know this is the ump-teenth embedding question, but here goes. I need to > embed Jpython into a Java application, however I want to launch an > AWT/Swing > window with interpreter somehow. I have not found any examples related to > this, so I am curious how I could do this. If anyone has wrapped a python > interpreter in a Swing window please let me know - thanks. > > Jim > > > _______________________________________________ > JPython-Interest maillist - JPy...@py... > http://www.python.org/mailman/listinfo/jpython-interest |
From: cch <fr...@ms...> - 2000-12-12 21:02:59
|
Hi: Is that possisble to use Jython with JSP? cch |
From: <Wil...@FI...> - 2000-12-12 13:46:22
|
hi there, We're looking to create a wrapper around Oracle's sqlplus using jpython (jython). The idea being that users give sql statements which are pre-processed by our system and then sent (changed or unchanged as required) to sqlplus to be actioned on the database. We got it working by writing to a file and calling os.system('sqlplus user/pass @file'), but we're wondering now if it wouldn't be possible to create a more-permanent instance of sqlplus running as a sub-process and pass it lines of sql to action straight away... something along the lines of.. >>> from jnios import os >>> sqlproc = os.popen('sqlplus user/pass','w') >>> sqlproc.write(sqlstatement) >>> sqlproc.flush() I'm having a few problems with this. It seems very difficult to send it a string that it likes. I'm getting all sorts of "SIGBUS 10 bus error". Hopefully the dump below makes sense to somebody >>> sqlproc.write('select * from cat;\n') SIGBUS 10 bus error si_signo [10]: BUS si_errno [0]: si_code [1]: BUS_ADRALN [addr: 0x4cf62e] stackpointer=FFBEC538 Exiting Thread (sys_thread_t:0xff30c2e8) : no stack Exiting Thread (sys_thread_t:0x2e6e10) : no stack Exiting Thread (sys_thread_t:0x2e6bf8) : no stack Exiting Thread (sys_thread_t:0x2e69e0) : no stack "Finalizer" (TID:0x155a10, sys_thread_t:0x155948, state:CW, thread_t: t@6, threadID:0xfec81dc8, stack_bottom:0xfec82000, stack_size:0x20000) prio=8 We are using Solaris by the way. If anyone out there can help (even if its just to say "it works for me"), it would be much appreciated... - will w eSafe Protect Gateway (tm) has scanned this mail for viruses, vandals and suspicious attachments and has found it to be CLEAN. |
From: Nick M. <ni...@re...> - 2000-12-12 06:28:47
|
[This may be a dev question; I'm not sure.] Has anybody had any success in writing EJB's with jythonc? I've looked superficially at jythonc's output and at v1.1 of the EJB spec, and it seems that there is at least one incompatibility: EJB requires that beans not define a 'finalize' method, and jythonc insists on defining a proxy for every inherited protected method, including 'finalize'. 1) Is this the only obstacle? If so, there ought to be a way to suppress unwanted proxies. Is it worth my while to hack one up? What interface would be appropriate? 2) If there are other obstacles to using jythonc with EJB, can anybody summarize them? I'd like to get to know the jython source, and this seems a good way to start. I thank you for your time, -- Nick Mathewson |
From: irwan <ry...@tm...> - 2000-12-11 05:57:27
|
Thanks I've changed the code from null to None and it's work... ----- Original Message ----- From: irwan To: jyt...@li... Sent: Monday, December 11, 2000 12:32 PM Subject: How to setBounds with JPython/Jython Hi all I'm newbie in jpython/jython. I would like to write a simple jython code within swing module that's include setBounds method. It seems only work for the first widget. In java u need to set setLayout to null but when i'm trying to do the same thing i get an error. Below is i simple code in jython that using setBound method which is only work for the first widget. That's mean only jL1 will effect and not (jL / jL2) |
From: Adam B. <ada...@gb...> - 2000-12-11 04:25:04
|
Irwan wrote: > Hi all > > I'm newbie in jpython/jython. I would like to write a simple jython code > within swing module that's include setBounds method. > It seems only work for the first widget. In java u need to set setLayout > to null but when i'm trying to do the same thing i get an error. > What's the error? I realise it's an obvious question, but "null" isn't a keyword in Python. "None" is used instead. Adam Burke www.gbst.com -- Oh, America happened to America and it was all downhill from there. -- Bronwyn Sharman <ignore useful code sample> |
From: irwan <ry...@tm...> - 2000-12-11 04:09:24
|
Hi all I'm newbie in jpython/jython. I would like to write a simple jython code within swing module that's include setBounds method. It seems only work for the first widget. In java u need to set setLayout to null but when i'm trying to do the same thing i get an error. Below is i simple code in jython that using setBound method which is only work for the first widget. That's mean only jL1 will effect and not (jL / jL2) frame=swing.JFrame("Data Extraction",visible=1) #a=java.awt.FlowLayout() #frame.contentPane.setLayout(a) exitMenu=swing.JMenu('File') fileItem1=swing.JMenuItem('Open',actionPerformed=action) exitMenu.add(fileItem1) exitItem1=swing.JMenuItem('Quit',actionPerformed=action) exitMenu.add(exitItem1) menuBar1=swing.JMenuBar() menuBar1.add(exitMenu) jL1=swing.JLabel("Extraction Method") jL1.setBounds(5,5,200,100) frame.contentPane.add(jL1) jL=swing.JLabel("Run Stored Procedure") jL.setBounds(5,20,200,100) frame.contentPane.add(jL) frame.setJMenuBar(menuBar1) #jT=swing.JTextField("00-MON-YY",10) #jT.setBounds(50,50,50,10) #frame.contentPane.add(jT) jL2=swing.JButton("Run ", actionPerformed=storcProc) jL2.setBounds(20,50,10,10) frame.contentPane.add(jL2) frame.setSize(300,200) frame.show() |
From: Ben H. <be...@in...> - 2000-12-11 01:26:02
|
Hi Anton, Anton Gluck wrote: > I am working on a project for which a data analyzing algorithm was written > in Java, and wrote a JPython 1.5.2 script to test the algorithm. When > analyzing large data sets (flat text files) of more than 20, 30 MB we > originally faced two problems: This was slow, and we ran out of memory > even if the JVM is allocated the full 256 MB RAM. After rewriting the > JPython code the out-of-memory problem went away, but presumably the limit > was just pushed a little further. I read an interesting article recently about the differences bewteen virtual machine versions in memory usage behavior. Earlier, non-hotspot VMs throw Out Of Memory much earlier and easier than hotspot. Hotspot appears to utilize the JVM process allocated memory more efficiently, so that more of it 90%+ can be allocated to objects without throwing OutOfMemory, compared to 60-70% on older VMs. This article was on a public Sun webserver, which I got to from the bug parade while investigating garbage collection. So, one piece of advice would be upgrade your VM version if possible. Ben -- Ben Hutchison Software Engineer-Market Predictor Webmind Australia http://www.webmind.com/productspredictor.html |
From: <bc...@wo...> - 2000-12-10 19:31:49
|
[Anton Gluck] >I'd like to solicit your response on how useful JPython/Jython is when >analyzing large data sets. > >I am working on a project for which a data analyzing algorithm was written >in Java, and wrote a JPython 1.5.2 script to test the algorithm. When >analyzing large data sets (flat text files) of more than 20, 30 MB we >originally faced two problems: This was slow, and we ran out of memory >even if the JVM is allocated the full 256 MB RAM. After rewriting the >JPython code the out-of-memory problem went away, but presumably the limit >was just pushed a little further. > >In short, this is what the script does: It reads the flat file and builds >Java objects holding data records (really just arrays of doubles). The >records are built and handed to the analyzing algorithm one at a time. >Java classes analyze the data, and create objects describing the results. >The script then examines the results and writes out some diagnostics. In >order to do this, the data set is read twice more (reading it once and >holding the data in memory had let to the out-of-memory problem). I'll assume a data record object like this. class DataRec { public double[] data; } > >So my question is: Is JPython a useful tool for this kind of testing? Do >we need to be concerned about memory leaks when handling large data sets? There are no known leaks in the handling of normal objects. (The known leaks in jython are around class loading, generated event adapters and threads). You will still have to deal with possible deallocation of global data structures when they are no longer needed. This is standard python issues, not specially related to jython. Jython compares differently than Python in memory consumption. Exact measurement is almost impossible, but here some of what I know: - Each java object carry an additional ~8-16 bytes overhead, depending of JVM version and object type. An array instance also have this overhead. - A java object in jython will be wrapped with an instance of PyJavaInstance. So if you store the data records in a jython list or jython dict, there is a 36-44 bytes overhead for each data record. If you store the data records in a java.util.Vector instead you save this memory overhead, but will instead force jython to create a new wrapper each time a data record is retrieved from the Vector. (The numbers above are so dependent on the JVM to be practically useless, but I'm assuming 4 bytes for an objet reference). >We also have a Python script that tests the C++ version of the algorithm, >and it runs considerably faster on the same machine (by about half). Would >you say that this is solely because of the difference between Java and >C++, or are there additional factors influencing the speed of execution? I would say the java solution is holding up quite good if that is you measurements. It is highly dependent of the JVM and JIT. The ratio is also dependent of how much of the time is spend in the Java/C++ algorithm and how much in the script. It could be a possible performance improvement to let the data record subclass PyObject. That way the PyJavaInstance overhead is reduced completely. PyObject subclasses can be stored in python lists and dicts without creating a wrapper first. If the script also look at the double data, each access to a double will also create a new temporary object (a PyFloat), which may explain some of the difference. >Considering the out-of-memory problem: Is this a general Python problem, >or is it more pronounced in JPython? I don't know what overhead CPython have for each object, but I would guess that the overhead is bigger in Jython. >I realize that these are difficult questions to answer because of their >generality. But we would like to make an educated decision for future >projects - whether to stay with JPython/Jython (and Python) or to look for >alternatives. Performance enhancement are always difficult, because it is always possible to improve performance/memory-use a little. At some point the gain is just to small to worth the work. I suggest you try to let your data record subclass PyObject. That should give a relative large memory saving. If that isn't enough, cut your losses and use an environment where you have better control over memory allocation and memory use. regards, finn |
From: George H. <ghe...@cf...> - 2000-12-10 17:27:52
|
Anton Gluck wrote: > > I'd like to solicit your response on how useful JPython/Jython is when > analyzing large data sets. I don't feel particularly qualified to comment on the usefulness of Jython for your particular problem; however, there are the usual concerns when using a scripting language to be taken into account. Generally, both execution time and memory requirements are somewhat higher for scripting languages. > I am working on a project for which a data analyzing algorithm was written > in Java, and wrote a JPython 1.5.2 script to test the algorithm. When > analyzing large data sets (flat text files) of more than 20, 30 MB we > originally faced two problems: This was slow, and we ran out of memory > even if the JVM is allocated the full 256 MB RAM. It is possible to allocate more than the available RAM to the JVM. Thiswill probably result in higher paging rates for your program in execution, but the degree of impact would depend on the locality of reference within your program. Some of the slowness you are experiencing currently is probably due to paging. > In short, this is what the script does: It reads the flat file and builds > Java objects holding data records (really just arrays of doubles). Reducing the number of objects your program works with is always a god idea, and using native types (e.g. doubles) is useful from a performance perspective. It sounds as if you are already taking this advice, but it never hurts to re-examine your design. Also, there may be an opportunity to reduce the amount of data worked on at one time. That is it may be possible to work on the data in chunks instead of all at once. > We also have a Python script that tests the C++ version of the algorithm, > and it runs considerably faster on the same machine (by about half). Would > you say that this is solely because of the difference between Java and > C++, or are there additional factors influencing the speed of execution? My comment above about paging may be applicable. I won't weigh in on the Java/C++ debate. Good luck, George |
From: Anton G. <gl...@mi...> - 2000-12-10 04:55:07
|
Hi, I'd like to solicit your response on how useful JPython/Jython is when analyzing large data sets. I am working on a project for which a data analyzing algorithm was written in Java, and wrote a JPython 1.5.2 script to test the algorithm. When analyzing large data sets (flat text files) of more than 20, 30 MB we originally faced two problems: This was slow, and we ran out of memory even if the JVM is allocated the full 256 MB RAM. After rewriting the JPython code the out-of-memory problem went away, but presumably the limit was just pushed a little further. In short, this is what the script does: It reads the flat file and builds Java objects holding data records (really just arrays of doubles). The records are built and handed to the analyzing algorithm one at a time. Java classes analyze the data, and create objects describing the results. The script then examines the results and writes out some diagnostics. In order to do this, the data set is read twice more (reading it once and holding the data in memory had let to the out-of-memory problem). So my question is: Is JPython a useful tool for this kind of testing? Do we need to be concerned about memory leaks when handling large data sets? We also have a Python script that tests the C++ version of the algorithm, and it runs considerably faster on the same machine (by about half). Would you say that this is solely because of the difference between Java and C++, or are there additional factors influencing the speed of execution? Considering the out-of-memory problem: Is this a general Python problem, or is it more pronounced in JPython? I realize that these are difficult questions to answer because of their generality. But we would like to make an educated decision for future projects - whether to stay with JPython/Jython (and Python) or to look for alternatives. Thank you for any responses. Anton |
From: <bc...@wo...> - 2000-12-09 18:58:45
|
[Mats Wichmann] >Pretty new to Jython, and faced with having to write something >sensible about it (for a class I'm putting together). Sigh. > >Anyway, looking over the demo programs that (still) come with >the current alpha, and I can't get the example in "javaclasses" >to work. The output trace is attached. Any suggestions >welcomed... >Command (as described in readme.txt): >jythonc -package pygraph Graph.py >========= > >Warning: -package is deprecated, use --package Thanks for the feedback. I'll update the readme.txt to use the --package option. >[...] > >Compiling .java to .class... >Compiling with args: ['C:\\PROGRAM FILES\\JAVASOFT\\JRE\\1.3\\bin\\javac', ... >1 java.io.IOException: CreateProcess: "C:\PROGRAM FILES\JAVASOFT\JRE\1.3\bin\javac" ... This is most likely because you used the JRE to install Jython. The JRE does not include a java compiler. If the JRE is the only JVM you have installed, you will need to install the full JDK. If you have installed the full JDK already, you may need to specify the full path to the JDK java.exe when installing Jython, ie: c:\java\jdk1.3\bin\java -cp . Jython-20a1 where c:\java is the path you specified when you installed the JDK. I have very recently added additional information to the install.html page which hopefully will help other from falling into the same problems. regards, finn |
From: Mats W. <ma...@la...> - 2000-12-09 03:56:31
|
Pretty new to Jython, and faced with having to write something sensible about it (for a class I'm putting together). Sigh. Anyway, looking over the demo programs that (still) come with the current alpha, and I can't get the example in "javaclasses" to work. The output trace is attached. Any suggestions welcomed... Mats Wichmann |
From: <bc...@wo...> - 2000-12-05 17:40:55
|
[Chris Knight] >all, I'm curious how I would define argument keywords for Java methods so >that Jython code can pass keyword arguments to it. You define a java method with a signature exactly like this: public void foo(PyObject[] args, String[] kws) { } The first elements of args are the positional arguments and the last kws.length elements of args are keyword argument values with the keyword names in kws. There are also an experimental ArgParser class that helps out with interpreting these two parameters. Look at the org/python/modules/sre/ PatternObject.java source for examples. >Additionally, I'm wondering if it would be worthwhile to start an advanced >developer's guide/FAQ? I would rather keep it all in the current FAQ. That way I don't have to decide when a topic is advanced. >Such topics could include: > >* Java classes that support PyList and PyDictionary mechanisms >* Java classes that support __call__/invoke mechanisms These questions would fit nicely under section 5. "Extending Jython." http://jython.sourceforge.net/cgi-bin/faqw.py?req=add regards, finn |
From: Chris K. <ck...@ma...> - 2000-12-05 16:58:28
|
all, I'm curious how I would define argument keywords for Java methods so that Jython code can pass keyword arguments to it. Additionally, I'm wondering if it would be worthwhile to start an advanced developer's guide/FAQ? Such topics could include: * Java classes that support PyList and PyDictionary mechanisms * Java classes that support __call__/invoke mechanisms ??? |
From: Boudewijn R. <bo...@re...> - 2000-12-05 09:37:08
|
On Mon, 4 Dec 2000, Finn Bock wrote: > > I hope you can make use of: This is cool! It is intended to used this > way! Just do it! > <...> > > Yes. Very nice. > Thanks for those kind words... It means that I can now almost safely say that Tryllian (http://www.tryllian.com) will use Jython as the scripting extension of their management tool for the habitat servers for the mobile, intelligent agents ;-). Boudewijn Rempt | http://www.valdyas.org |
From: Pavel T. <pau...@ya...> - 2000-12-05 03:24:17
|
Irwan, I changed your code a little bit, now it shows both JLabel and JText. But jL.setBounds do not work anyway (and will not work) because you use layout manager. That means container will not take current component size into account, but only preferred size (for labels, it is computed based on label text, some insets and font that will be used for rendering). Hope this helps, Pavel PS I did not try it with Jython -- I still use JPython 1.1 but it should not make any difference for your question. from pawt import swing import java frame=swing.JFrame("Test",visible=1) frame.contentPane.layout = java.awt.FlowLayout() jL=swing.JLabel("Python") frame.contentPane.add(jL) jL.setBounds(10,10,10,10) jT=swing.JTextField("Test",10) frame.contentPane.add(jT) frame.setSize(300,200) frame.show() --- irwan <ry...@tm...> wrote: > Hi all, > > I would like to write a simple GUI (java swing) with > jython which have a JLabel and JTextField. > My problem is to setbouds to JLabel but it doesn't > effect it. Meanwhile in JTextField, i cannot to set > the size. My screen show white color with text > "Test" in the middle. > > from pawt import swing > import java > > frame=swing.JFrame("Test",visible=1) > a=java.awt.FlowLayout() > jL=swing.JLabel("Python") > frame.contentPane.add(jL).setLayout(a) > jL.setBounds(10,10,10,10) > jT=swing.JTextField("Test",10) > frame.contentPane.add(jT).setLayout(a) > frame.setSize(300,200) > frame.show() > > __________________________________________________ Do You Yahoo!? Yahoo! Shopping - Thousands of Stores. Millions of Products. http://shopping.yahoo.com/ |
From: irwan <ry...@tm...> - 2000-12-05 01:12:14
|
Hi all, I would like to write a simple GUI (java swing) with jython which have a JLabel and JTextField. My problem is to setbouds to JLabel but it doesn't effect it. Meanwhile in JTextField, i cannot to set the size. My screen show white color with text "Test" in the middle. from pawt import swing import java frame=swing.JFrame("Test",visible=1) a=java.awt.FlowLayout() jL=swing.JLabel("Python") frame.contentPane.add(jL).setLayout(a) jL.setBounds(10,10,10,10) jT=swing.JTextField("Test",10) frame.contentPane.add(jT).setLayout(a) frame.setSize(300,200) frame.show() |
From: <bc...@wo...> - 2000-12-04 23:15:10
|
[Boudewijn Rempt] >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! ;-). I hope you can make use of: This is cool! It is intended to used this way! Just 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. If you take a look at at org/python/util/PythonInterpreter and its set() method you will see that it too takes an Object as a generic value. public void set(String name, Object value) { ... } This method is solving exactly the same problem of setting a local variable in a python namespace. >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? Yes. Very nice. regards, finn |