Ticket #3930 (closed defect: fixed)
t.i._pollingfile silently accepts unicode for writing
| Reported by: | dotz | Owned by: | therve |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | core | Keywords: | win32 |
| Cc: | Branch: | branches/pollingfile-unicode-3930 | |
| Author: | therve | Launchpad Bug: |
Description
Hi,
this little bug took me about 3 hours to track. I use tx ampoule https://launchpad.net/ampoule on win32 (Vista). Some AMP commands were passed correctly over ampoule; some were not and it looked like every single byte was separated by a NULL byte... As it came out, unicode string was passed to t.i._pollingfile write function and the AMP command sent by ampoule and Twisted amp was received mangled.
I propose we disallow writing unicode objects. If user wants to write unicode, he/she will have to convert it to utf-8 string before.
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

