RE: [Zope] Strange error with Photo Product
Ron Bickers wrote:
Error Type: KeyError Error Value: the_file
File Script (Python), line 8, in photo_upload
line 8 >>> the_file = request['the_file'] Try using request.form['the_file'] instead. _______________________ as a possible way to resolve a problem with the Photo which throws a KeyError exception on the input file name. I tried the suggested change with no effect. (Inspection of the REQUEST structure had already established that it was reasonable and without name conflicts.) Perhaps it was not clear from my posting: the upload process completes successfully prior to the point where the exception is thrown. Moreover, I have checked the type of the form variable, 'the_file' and it is correct as is its contents. As the problem is still with me, any further suggestions would be appreciated.
-----Original Message----- From: Dennis Allison [mailto:allison@sumeru.stanford.EDU]
Perhaps it was not clear from my posting: the upload process completes successfully prior to the point where the exception is thrown. Moreover, I have checked the type of the form variable, 'the_file' and it is correct as is its contents.
I'm not sure what else to try. Are you saying that manage_addPhoto completes *before* the exception? The exception you posted is pretty clear to me -- line 8 (before manage_addPhoto), no 'the_file' key in the 'request' var. How can the line after it be successful if this is the case? _______________________ Ron Bickers Logic Etc, Inc.
participants (2)
-
Dennis Allison -
Ron Bickers