Message11659

Author jeff.allen
Recipients jeff.allen, stefan.richthofer, zyasoft
Date 2017-11-18.10:37:18
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1511001439.55.0.213398074469.issue2638@psf.upfronthosting.co.za>
In-reply-to
Content
Jim: good. I'll go that way then, by which I mean make the unicode methods consistently tolerant. Also for unicode a and b, a + T(b.encode()) = a + b. However:

1. T(a.encode()) + b will still be a T or an error. (It's up to T.__add__.) I thought I should have a unicode.__radd__, but not on second thoughts.

2. Tests for equality should do what CPython does: I'm thinking of the surprises assertEqual() and containers indexed by strings might throw up.

There are a few places around the codebase where "if it's not ascii it's not acceptable". In *some* of them, I think the CPython behaviour will be "if it doesn't decode it's not acceptable". Because any other default encoding is deprecated, this is not really tested in the regression suite. Fixing things here will probably move the focus along to those for a few users.
History
Date User Action Args
2017-11-18 10:37:19jeff.allensetmessageid: <1511001439.55.0.213398074469.issue2638@psf.upfronthosting.co.za>
2017-11-18 10:37:19jeff.allensetrecipients: + jeff.allen, zyasoft, stefan.richthofer
2017-11-18 10:37:19jeff.allenlinkissue2638 messages
2017-11-18 10:37:18jeff.allencreate