From: Stephen N. <ste...@co...> - 2002-01-26 00:11:17
|
Hi, I would like to write a cgi program using Jython as opposed to Python. I know this has it's disadvantages regarding performance, but it's just something I am playing with. When I submit a form to the Jython CGI program, it fails to get any values (text input) from the form and the cgi.FieldStorage is None. Am I correct in saying cgi.FieldStorage() is not supported? Thanks Stephen Naicken - ste...@co... |
From: Kevin B. <kb...@ca...> - 2002-01-26 01:04:42
|
At a guess, I'd say you're using a version of Jython older than 2.1. Versions before 2.1 had no support for environment variables, which are pretty necessary for the cgi module... (and getting environment variables in Jython is just one more performance problem for the jython choice, but that's another story... :-) ) try 'jython cgi.py' in the jython/Lib directory, and look for the Shell Environment section. If it is empty, your jython version is too old, and you need to grab the new one from www.jython.org when SourceForge gets the files back up. If you are using 2.1, there is evidently another requirement for the cgi module to work. :-( kb Stephen Naicken wrote: > > Hi, > > I would like to write a cgi program using Jython as opposed to Python. > I know this has it's disadvantages regarding performance, but it's just > something I am playing with. > > When I submit a form to the Jython CGI program, it fails to get any > values (text input) from the form and the cgi.FieldStorage is None. Am > I correct in saying cgi.FieldStorage() is not supported? > > Thanks > > Stephen Naicken - ste...@co... > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > https://lists.sourceforge.net/lists/listinfo/jython-users |
From: Stephen N. <ste...@co...> - 2002-01-26 14:37:04
|
Thanks for your advice Kevin. The CGI server I was using was based on cPython's CGIHTTPServer and the CGI script was in Jython. I changed the #! /local/bin/python to #! /usr/bin/env jython for the server, it detected the environment variable successfully. I'm not sure what the logic is behind this though and I think it is very strange. Anyway all working now! On Fri, 25 Jan 2002, Kevin Butler wrote: > At a guess, I'd say you're using a version of Jython older than 2.1. > > Versions before 2.1 had no support for environment variables, which are pretty necessary for the cgi module... > (and getting environment variables in Jython is just one more performance problem for the jython choice, but that's another story... :-) ) > > try 'jython cgi.py' in the jython/Lib directory, and look for the Shell Environment section. If it is empty, your jython version is too old, and you need to grab the new one from www.jython.org when SourceForge gets the files back up. > > If you are using 2.1, there is evidently another requirement for the cgi module to work. :-( > > kb > > Stephen Naicken wrote: > > > > Hi, > > > > I would like to write a cgi program using Jython as opposed to Python. > > I know this has it's disadvantages regarding performance, but it's just > > something I am playing with. > > > > When I submit a form to the Jython CGI program, it fails to get any > > values (text input) from the form and the cgi.FieldStorage is None. Am > > I correct in saying cgi.FieldStorage() is not supported? > > > > Thanks > > > > Stephen Naicken - ste...@co... > > > > _______________________________________________ > > Jython-users mailing list > > Jyt...@li... > > https://lists.sourceforge.net/lists/listinfo/jython-users > Stephen Naicken "It's all about the game and how you play it" - The Game |
From: Stephen N. <ste...@co...> - 2002-02-21 16:25:06
|
I have an application in python that requires the use of the bsddb module to extract information from the mozilla 0.92 cache database, cache.db. I would like to port this application to jython, but the bsddb module is not available. What alternatives do i have? Thanks Stephen |
From: Jeff E. <je...@ad...> - 2002-02-21 17:01:20
|
You can find a Java interface to Berkeley DB which you can access directly from jython. Feed this to google "berkeley db java" Stephen Naicken wrote: > I have an application in python that requires the use of the bsddb > module to extract information from the mozilla 0.92 cache database, > cache.db. I would like to port this application to jython, but the > bsddb module is not available. What alternatives do i have? > > Thanks > > Stephen > > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > https://lists.sourceforge.net/lists/listinfo/jython-users > |
From: Stephen N. <ste...@co...> - 2002-02-28 20:35:09
|
Slightly off topic from jython, but does the berekely db java interface support version 1.85 if conifgured with the 1.85 compatablity? On Thu, 21 Feb 2002, Jeff Emanuel wrote: > > > You can find a Java interface to Berkeley DB which you can access > directly from jython. Feed this to google "berkeley db java" > > > Stephen Naicken wrote: > > > I have an application in python that requires the use of the bsddb > > module to extract information from the mozilla 0.92 cache database, > > cache.db. I would like to port this application to jython, but the > > bsddb module is not available. What alternatives do i have? > > > > Thanks > > > > Stephen > > > > > > _______________________________________________ > > Jython-users mailing list > > Jyt...@li... > > https://lists.sourceforge.net/lists/listinfo/jython-users > > > > > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > https://lists.sourceforge.net/lists/listinfo/jython-users > |