[Zope3-Users] testbrowser and file upload
darryl at darrylcousins.net.nz
Mon Jul 3 18:45:38 EDT 2006
I have found a strange behaviour with testbrowser and file objects. What
appears to happen is that the cStringIO.StringIO that I pass to the file
control in a form is converted to unicode before reaching the view
handler. This then raises AttibuteError: Unicode has no read attribute.
I have attached created a test that demonstrates this behaviour and the
catches that I needed to add to my view handler (which is code from
schoolbell csv import). I've yet to see what needs to be done if it is
an image I am trying to upload.
The README from the test package is here:
The package code can be viewed here:
Or the full test package can be obtained here:
More information about the Zope3-users