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 serhiy.storchaka
Recipients doerwalter, ezio.melotti, lemburg, ncoghlan, serhiy.storchaka, vstinner
Date 2013-11-19.15:41:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1384875700.08.0.383874659581.issue19619@psf.upfronthosting.co.za>
In-reply-to
Content
Blacklisting by name is slow and it prevents a user from defining a codec with blacklisted name.

What if just add private attribute ("_not_text"?) to unsafe codecs? If a codec has this attribute, than it should not be used it text encoding/decoding. Checking an attribute is much faster than comparing with a couple of strings.

Another possibility is an inheriting all unsafe codecs from special class.
History
Date User Action Args
2013-11-19 15:41:40serhiy.storchakasetrecipients: + serhiy.storchaka, lemburg, doerwalter, ncoghlan, vstinner, ezio.melotti
2013-11-19 15:41:40serhiy.storchakasetmessageid: <1384875700.08.0.383874659581.issue19619@psf.upfronthosting.co.za>
2013-11-19 15:41:40serhiy.storchakalinkissue19619 messages
2013-11-19 15:41:40serhiy.storchakacreate