From 02706fcafa4b8d8f06ce3e4ca572371ac9c089a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timoth=C3=A9e=20Mazzucotelli?= Date: Tue, 20 Aug 2024 14:28:34 +0200 Subject: [PATCH] chore: Revert debug message about objects exposed from external modules --- src/_griffe/loader.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/_griffe/loader.py b/src/_griffe/loader.py index d8b85d23..0958f590 100644 --- a/src/_griffe/loader.py +++ b/src/_griffe/loader.py @@ -16,7 +16,6 @@ AliasResolutionError, CyclicAliasError, LoadingError, - NameResolutionError, UnimportableModuleError, ) from _griffe.expressions import ExprName @@ -296,15 +295,6 @@ def expand_exports(self, module: Module, seen: set | None = None) -> None: logger.warning("Unsupported item in %s.__all__: %s (use strings only)", module.path, export) # It's a string, simply add it to the current exports. else: - with suppress(NameResolutionError): - if not module.resolve(export).startswith(module.path): - # NOTE: This won't work for built-in attributes during inspection, - # since their canonical module cannot be determined. - logger.debug( - "Name `%s` exported by module `%s` doesn't come from this module or from a submodule.", - export, - module.path, - ) expanded.add(export) module.exports = expanded