Author lemburg
Recipients ezio.melotti, lemburg, vstinner
Date 2020-09-23.13:04:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <01f40a2b-ebc1-c80a-cb8b-a9d32a3917e4@egenix.com>
In-reply-to <1600865818.68.0.279745610542.issue41842@roundup.psfhosted.org>
Content
On 23.09.2020 14:56, STINNER Victor wrote:
> Marc-Andre Lemburg explained:
> 
> "There is no API to unregister a codec search function, since deregistration
> would break the codec cache used by the registry to speedup codec
> lookup."
> 
> One simple solution would be to clear the cache (PyInterpreterState.codec_search_cache) when codecs.unregister() removes a search function. I expect that calling unregister() is an uncommon operation, so the performance is not a blocker issue.

+1

BTW: While you're at it, having a way to access the search function
list from Python would be nice as well, since this would then open
up the possibility to reorder search functions.

-- 
Marc-Andre Lemburg
eGenix.com

Professional Python Services directly from the Experts (#1, Sep 23 2020)
>>> Python Projects, Coaching and Support ...    https://www.egenix.com/
>>> Python Product Development ...        https://consulting.egenix.com/
________________________________________________________________________

::: We implement business ideas - efficiently in both time and costs :::

   eGenix.com Software, Skills and Services GmbH  Pastor-Loeh-Str.48
    D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg
           Registered at Amtsgericht Duesseldorf: HRB 46611
               https://www.egenix.com/company/contact/
                     https://www.malemburg.com/
History
Date User Action Args
2020-09-23 13:04:00lemburgsetrecipients: + lemburg, vstinner, ezio.melotti
2020-09-23 13:04:00lemburglinkissue41842 messages
2020-09-23 13:04:00lemburgcreate