Oops. My bad. I did in fact have this line of code before calls to form: form = cgi.FieldStorage()
I changed the except command from "pass" to "print sys.exc_info()" as per your suggestion. Still, however, the form just renews itself without offering any information whatsoever. You can see this here, if you like: http://13gems.com/test-Calculators_frame.py TIA, beno On Thu, Jul 23, 2009 at 2:01 PM, Dennis Lee Bieber <wlfr...@ix.netcom.com>wrote: > On Thu, 23 Jul 2009 12:46:16 -0300, Victor Subervi > <victorsube...@gmail.com> declaimed the following in > gmane.comp.python.general: > > > sent. Here again is the code: > > > > from primeNumbers import primeNumbers > > > > try: > > lang = form.getfirst('lang', 'en') > > This code is incomplete -- where is "form" created? I see no > "import"s that might define such... > > > browser = form.getfirst('browser', 'all') > > site = form.getfirst('site', 'bridge') > > num = form.getfirst('num','') > > except: > > pass > > Since there is no such thing as "form" in the code you posted, the > first "form.getfirst()" operation will raise an exception. That > exception is then being ignored by this "pass". > > I'd suggest moving the code that outputs the HTTP response header > and the HTML prelude material to the top, then replace "pass" with > something that prints actual exception information (the stuff from > sys.exc_info() ) > -- > Wulfraed Dennis Lee Bieber KD6MOG > wlfr...@ix.netcom.com wulfr...@bestiaria.com > HTTP://wlfraed.home.netcom.com/ > (Bestiaria Support Staff: web-a...@bestiaria.com) > HTTP://www.bestiaria.com/ > > -- > http://mail.python.org/mailman/listinfo/python-list >
-- http://mail.python.org/mailman/listinfo/python-list