[Python-3000] need help fixing broken tests in py3k-pep3137 branch

Brett Cannon brett at python.org
Sat Nov 3 08:39:32 CET 2007

On 11/2/07, Guido van Rossum <guido at python.org> wrote:
> In the py3k-pep3137 branch I've been working on the implementation of PEP 3137.
> The work is largely done, but I'm stuck with about 20 failing tests,
> and very little time this weekend to work on these. Here's the list:

I decided to look at a few of these tests before I went to bed.  Here
is what I found out:

> test_array

_fileio.c for read() calls is using PyBytes instead of PyString, so a
type check in array.array().fromfile() is failing.  I am assuming that
_fileio.c should be moved from PyBytes to PyString, right?

There is another failure but I didn't look at it.

> test_exceptions

pickle is returning buffers for pickled bytes::

  >>> pickle.loads(pickle.dumps(b'bytes'))

Obviously that's not right.  =)

> test_httplib

Fixed in revision 58823.  HTTPConnection.putheaders() was doing "%s:
%s" but not checking if its arguments were strings or bytes/buffers.
Changed so that if the function's arguments had an 'encode' method it
is called so that instead of string interpolation bytes concatenation
is used.

> test_import (*)

This is passing for me on OS X 10.4.


More information about the Python-3000 mailing list