bug or feature in enum34 py2.7 backport?

Chris Angelico rosuav at gmail.com
Wed Nov 26 10:46:44 EST 2014


On Thu, Nov 27, 2014 at 2:32 AM,  <random832 at fastmail.us> wrote:
> But why shouldn't the type constructor do the conversion (and any
> validation of being ASCII-only) when parsing the arguments? The root
> cause seems to be that it parses its arguments with "SO!O!:type"
> (typeobject.c, line 2097). Does anyone know what problems would be
> caused, in general, by having S do a conversion if provided with a
> unicode object?
>
> It seems like if it is a bug to reject long where int is accepted, it
> should be likewise considered a bug to reject ASCII-only unicode where
> str is accepted.

Hmm, that sounds like it would be a feature improvement, rather than a
bug fix. But you could take that up with the release manager.

ChrisA



More information about the Python-list mailing list