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 brett.cannon
Recipients Arfrever, barry, brett.cannon, eric.smith, eric.snow, georg.brandl, ncoghlan, python-dev
Date 2012-08-02.18:16:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1343931421.5.0.329733444065.issue15502@psf.upfronthosting.co.za>
In-reply-to
Content
I guess the question is how extensive do we want this cache validation to go? Do we think that only path entry finders stored in sys.path_importer_cache will have stuff to be cleared, or do we think stuff on sys.meta_path or sys.path_hooks will have things that need to get cleared as well? The more I think about it, the more I want to  generalize this to the point of sys.meta_path and then having PathFinder handle sys.path_hooks and sys.path_importer_cache. That stays in line with import not caring about sys.path, etc. and it really just being some cruft left over from Python 2.

Regardless, though, I would not define invalidate_caches() on Finder and instead define it separately on PathEntryFinder and MetaPathFinder. It's new in 3.3 so it doesn't need to be on Finder for backwards-compatibility, and it isn't inherent to finders. Plus if Finder goes away we will have to push it up to the other ABCs anyway.
History
Date User Action Args
2012-08-02 18:17:02brett.cannonsetrecipients: + brett.cannon, barry, georg.brandl, ncoghlan, eric.smith, Arfrever, python-dev, eric.snow
2012-08-02 18:17:01brett.cannonsetmessageid: <1343931421.5.0.329733444065.issue15502@psf.upfronthosting.co.za>
2012-08-02 18:17:00brett.cannonlinkissue15502 messages
2012-08-02 18:16:59brett.cannoncreate