This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author berker.peksag
Recipients Julian.Gindi, Tim.Graham, berker.peksag, bignose, brett.cannon, davidszotten@gmail.com, eric.snow, ezio.melotti, ncoghlan, rhettinger, serhiy.storchaka
Date 2016-10-12.09:53:42
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1476266022.79.0.312830417372.issue21720@psf.upfronthosting.co.za>
In-reply-to
Content
> Should we file a separate issue regarding the similarly vague error message from hasattr() itself?

+1 from me. It would be good to show users a user friendly message :)

> BytesWarning: Comparison between bytes and string

How about raising a TypeError if ``all(isinstance(l, str) for l in fromlist)`` is False? That would make the exception message less clearer since we can't include the "[...] not 'bytes'" part though.
History
Date User Action Args
2016-10-12 09:53:42berker.peksagsetrecipients: + berker.peksag, brett.cannon, rhettinger, ncoghlan, ezio.melotti, bignose, eric.snow, serhiy.storchaka, Julian.Gindi, davidszotten@gmail.com, Tim.Graham
2016-10-12 09:53:42berker.peksagsetmessageid: <1476266022.79.0.312830417372.issue21720@psf.upfronthosting.co.za>
2016-10-12 09:53:42berker.peksaglinkissue21720 messages
2016-10-12 09:53:42berker.peksagcreate