We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ac93c74 commit a453c02Copy full SHA for a453c02
bpython/curtsiesfrontend/repl.py
@@ -287,6 +287,18 @@ def find_distributions(self, context):
287
288
return None
289
290
+ def find_spec(self, fullname, path, target=None):
291
+ for finder in self.old_meta_path:
292
+ # Consider the finder only if it implements find_spec
293
+ if not getattr(finder, "find_spec", None):
294
+ continue
295
+ # Attempt to find the spec
296
+ spec = finder.find_spec(fullname, path, target)
297
+ if spec is not None:
298
+ # Patch the loader to enable reloading
299
+ spec.__loader__ = ImportLoader(self.watcher, spec.__loader__)
300
+ return spec
301
+
302
def find_module(self, fullname, path=None):
303
for finder in self.old_meta_path:
304
loader = finder.find_module(fullname, path)
0 commit comments