Message138463
As for the "<memory at %p>" string, when _io.BufferedWriter prepares the byte buffer into a PyMemoryView wrapper and passes it into the raw IO object:
res = PyObject_CallMethodObjArgs(self->raw, _PyIO_str_write, memobj, NULL);
For some reason, memobj.__repr__ is called before being passed to the raw IO's write method.
I can't reproduce this odd behavior using a dumb raw IO that extends _io.RawIOBase. Mimicking what pyserial does, however, reproduces both issues (see attached). |
|
Date |
User |
Action |
Args |
2011-06-16 20:13:08 | santoso.wijaya | set | recipients:
+ santoso.wijaya, pitrou, benjamin.peterson, OscarL |
2011-06-16 20:13:08 | santoso.wijaya | set | messageid: <1308255188.85.0.634689956595.issue12340@psf.upfronthosting.co.za> |
2011-06-16 20:13:08 | santoso.wijaya | link | issue12340 messages |
2011-06-16 20:13:08 | santoso.wijaya | create | |
|