From e77c8593559f393c62ab2f07d62759a274cb9faa Mon Sep 17 00:00:00 2001 From: Ethan Paul <24588726+enpaul@users.noreply.github.com> Date: Wed, 16 Dec 2020 19:14:03 -0500 Subject: [PATCH] Add additional logging to dependency processing functionality Hopefully this will help with dependency resolution errors in the future --- tox_poetry_installer/utilities.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/tox_poetry_installer/utilities.py b/tox_poetry_installer/utilities.py index 2a71a57..88bcae9 100644 --- a/tox_poetry_installer/utilities.py +++ b/tox_poetry_installer/utilities.py @@ -72,7 +72,6 @@ def find_transients(packages: PackageMap, dependency_name: str) -> Set[PoetryPac reporter.verbosity2( f"{constants.REPORTER_PREFIX} Skip {name}: designated unsafe by Poetry" ) - return dict() transients: PackageMap = {} @@ -87,11 +86,20 @@ def find_transients(packages: PackageMap, dependency_name: str) -> Set[PoetryPac f"{constants.REPORTER_PREFIX} Skip {package}: incompatible platform requirement '{package.platform}' for current platform '{sys.platform}'" ) else: - reporter.verbosity2(f"{constants.REPORTER_PREFIX} Include {package}") + reporter.verbosity2( + f"{constants.REPORTER_PREFIX} Including {package} for installation" + ) transients[name] = package - for dep in package.requires: + for index, dep in enumerate(package.requires): + reporter.verbosity2( + f"{constants.REPORTER_PREFIX} Processing dependency {index + 1}/{len(package.requires)} for {package}: {dep.name}" + ) if dep.name not in searched: transients.update(find_deps_of_deps(dep.name, searched)) + else: + reporter.verbosity2( + f"{constants.REPORTER_PREFIX} Package with name '{dep.name}' has already been processed, skipping" + ) return transients