[Python-Dev] registering unicode codecs

Neal Norwitz nnorwitz at gmail.com
Thu Nov 24 20:51:20 CET 2005


On 11/24/05, M.-A. Lemburg <mal at egenix.com> wrote:
>
> > Should users have access to the search path (through a
> > codecs.unregister())?
>
> Maybe, but why would you want to unregister a search function ?
>
> > If so, should it search from the end of the
> > list to the beginning to remove an item?  That way the last entry
> > would be removed rather than the first.
>
> I'd suggest to raise an exception in case a user tries
> to register a search function twice.

This should take care of the testing problem.

> Removal should be the
> same as doing list.remove(), ie. remove the first (and
> only) item in the list of search functions.

Do you recommend adding an unregister()?  It's not necessary for this case.

n


More information about the Python-Dev mailing list