Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #2498 Adding logging issue 2498 #2842

Merged
merged 9 commits into from
Aug 8, 2023
2 changes: 2 additions & 0 deletions kedro/framework/cli/micropkg.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
from typing import Any, Iterable, Iterator, List, Tuple, Union

import click
import logging
from build.util import project_wheel_metadata
from packaging.requirements import InvalidRequirement, Requirement
from packaging.utils import canonicalize_name
Expand Down Expand Up @@ -592,6 +593,7 @@ def _get_default_version(metadata: ProjectMetadata, micropkg_module_path: str) -
)
return micropkg_module.__version__ # type: ignore
except (AttributeError, ModuleNotFoundError):
logger.warning(f"Micropackage version not found in '{metadata.package_name}.{micropkg_module_path}', will take the top-level one in '{metadata.package_name}'")
# if micropkg version doesn't exist, take the project one
project_module = import_module(f"{metadata.package_name}")
return project_module.__version__ # type: ignore
Expand Down