Re: [Zope-dev] StringIO and Zope
[Oskar Wilhelmsen] > I can't print tracebacks. I'm unfortunatly on a windows system, an whats > happen is tha Python jus quits, with no fault description. > > A type(data) gives me DbiRaw, which is the type of data in the DB OK, can you break the line into two lines, as suggested before? Since you're getting no traceback info of any kind, it's impossible from what you've said so far to guess whether the problem is in StringIO or in DbiRaw's __str__ implementation. And since nobody else has said "ya, I see that too!", you're the only one who *can* supply additional info . ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] StringIO and Zope
Hi I can't print tracebacks. I'm unfortunatly on a windows system, an whats happen is tha Python jus quits, with no fault description. A type(data) gives me DbiRaw, which is the type of data in the DB -TOW - Original Message - From: "Tim Peters" <[EMAIL PROTECTED]> To: "Tor Oskar Wilhelmsen" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Monday, July 12, 2004 7:41 PM Subject: Re: [Zope-dev] StringIO and Zope > [Oskar Wilhelmsen] > > I have a problem with python 2.3.3 and Zope 2.7.0. When I Execute the code > > below, Python just get som unhandled exceptions, and crash? > > What are (exactly) the "unhandled exceptions"? Can you paste in tracebacks? > > > from cStringIO import StringIO > > #pic[3] is a blob in a database > > data = pic[3] > > > > fil = StringIO(str(data)) #this line makes Zope and Python crash > > Since you later said it didn't matter whether you used StringIO or > cStringIO, it would be helpful to beak that into two lines: > > temp = str(data) > fil = StringIO(temp) > > Might also help to print type(data). Since str() and StringIO() are > so heavily used, it's unlikely the problem is in either of them. Most > likely is a problem in type(data)'s __str__ or __repr__ > implementations. > ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
Re: [Zope-dev] StringIO and Zope
[Oskar Wilhelmsen] > I have a problem with python 2.3.3 and Zope 2.7.0. When I Execute the code > below, Python just get som unhandled exceptions, and crash? What are (exactly) the "unhandled exceptions"? Can you paste in tracebacks? > from cStringIO import StringIO > #pic[3] is a blob in a database > data = pic[3] > > fil = StringIO(str(data)) #this line makes Zope and Python crash Since you later said it didn't matter whether you used StringIO or cStringIO, it would be helpful to beak that into two lines: temp = str(data) fil = StringIO(temp) Might also help to print type(data). Since str() and StringIO() are so heavily used, it's unlikely the problem is in either of them. Most likely is a problem in type(data)'s __str__ or __repr__ implementations. ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )