diff --git a/lale/pretty_print.py b/lale/pretty_print.py index 4e4b21fe3..8e6391633 100644 --- a/lale/pretty_print.py +++ b/lale/pretty_print.py @@ -97,7 +97,7 @@ def value_to_string(value): elif isinstance(value, np.ufunc): if gen is not None: gen.imports.append("import numpy as np") - return f"np.{value.__name__}" + return f"np.{value.__name__}" # type: ignore elif isinstance(value, lale.expressions.Expr): if gen is not None: gen.imports.append("from lale.expressions import it") @@ -114,7 +114,7 @@ def value_to_string(value): gen.imports.append(f"import {module}") else: gen.imports.append(f"import {value.__module__} as {module}") - return f"{module}.{value.__name__}" + return f"{module}.{value.__name__}" # type: ignore elif hasattr(value, "get_params"): module = value.__module__ if module.startswith("sklearn."):