[PyQt] Python3 question

Detlev Offenbach detlev at die-offenbachs.de
Sun Mar 22 18:13:35 GMT 2009


On Sonntag, 22. März 2009, Phil Thompson wrote:
> On Sat, 21 Mar 2009 19:39:41 +0100, Detlev Offenbach
>
> <detlev at die-offenbachs.de> wrote:
> > Hi,
> >
> > I am in the process of writing a Python3 compatible debugger backend for
> > eric4. However, I am having a problem I cannot solve to to being not very
> >
> > familiar with the new Python3 stuff.
> >
> > Eric4 uses file like objects to buffer the socket connection to the debug
> >
> > server (= the IDE). That is implemented in AsyncFile.py. When I use this
> > file
> > with Python3, an exception is raised.
> >
> > TypeError('expected an object with the buffer interface',)
> >
> > What does this mean and what do I have to do to fix it?
> >
> > Thanks for any help.
>
> You are probably passing a string (ie. a unicode object) as an argument to
> a method of a bytes object. For example...
>
> b = b"foo"
> b.startswith("f")
>
> ...but this is Ok...
>
> b.startswith(b"f")
>
> Phil
> _______________________________________________
> PyQt mailing list    PyQt at riverbankcomputing.com
> http://www.riverbankcomputing.com/mailman/listinfo/pyqt

That was the problem. I solved it earlier today. And I am making progress with 
the Python3 debugger backend for eric4. In this process I noted, that the pdb 
debugger is broken. It doesn't stop at breakpoints. Mine does. :-))

Detlev
-- 
Detlev Offenbach
detlev at die-offenbachs.de



More information about the PyQt mailing list