You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The docs aren't super clear about this, but in practice the list actually contains classes (not objects), that implement MetaPathFinder, meaning meta_path : List[Type[MetaPathFinder]] instead of List[MetaPathFinder].
I think objects in sys.meta_path don't have to be classes, so Type[MetaPathFinder] isn't adequate either. Maybe we should use a Protocol? That way we could say "the objects in sys.meta_path have these methods, whatever type they actually have".
Activity
Akuli commentedon May 2, 2021
I think objects in
sys.meta_pathdon't have to be classes, soType[MetaPathFinder]isn't adequate either. Maybe we should use a Protocol? That way we could say "the objects insys.meta_pathhave these methods, whatever type they actually have".