Mon Jul 26 20:12:35 CDT 2010
[ I'm cc'ing the list on this, which may be of general interest ]
On Mon, Jul 26, 2010 at 2:14 PM, MinRK <email@example.com> wrote:
> Basically, the question revolves around what should we do with non-ascii
> unicode messages in this situation:
> s = b.recv()
Shouldn't send/receive *always* work with bytes and never with
unicode? Unicode requires knowing the encoding, and that is a
dangerous proposition on two sides of the wire.
If a message is unicode, it should be encoded first (to utf-8) and
decoded on the other side back to unicode.
There is then the question of the receiving side: should it always
decode? If not, should a flag about bytes/unicode be sent along?
More information about the IPython-dev