[Zope] Reading lines from a Zope File object

Chris Withers chris at simplistix.co.uk
Tue Jul 12 15:02:32 EDT 2005


J Cameron Cooper wrote:
> Yes, forgot that caveat. For large files, 'data' can return a "Pdata", a 
> list of strings. For small files, it returns a string. Always doing 
> 'str' is a good idea.

Well, there's a reason for PData ;-)

str'ing a large file will use lots of memory...

str'ing lots of large files in one transaction will topple your machine!

Chris

-- 
Simplistix - Content Management, Zope & Python Consulting
            - http://www.simplistix.co.uk



More information about the Zope mailing list