diff --git a/python_modules/libraries/dagster-components/dagster_components/cli/list.py b/python_modules/libraries/dagster-components/dagster_components/cli/list.py index bf3bd7db3d550..2ffdb2e6bfd54 100644 --- a/python_modules/libraries/dagster-components/dagster_components/cli/list.py +++ b/python_modules/libraries/dagster-components/dagster_components/cli/list.py @@ -5,7 +5,7 @@ import click -from dagster_components.core.component import ComponentMetadata, ComponentTypeRegistry +from dagster_components.core.component import ComponentTypeMetadata, ComponentTypeRegistry from dagster_components.core.deployment import ( CodeLocationProjectContext, find_enclosing_code_location_root_path, @@ -41,7 +41,7 @@ def list_component_types_command(ctx: click.Context) -> None: output: Dict[str, Any] = {} for key, component_type in context.list_component_types(): package, name = key.rsplit(".", 1) - output[key] = ComponentMetadata( + output[key] = ComponentTypeMetadata( name=name, package=package, **component_type.get_metadata(), diff --git a/python_modules/libraries/dagster-components/dagster_components/core/component.py b/python_modules/libraries/dagster-components/dagster_components/core/component.py index b40d4334d5f8b..a4e76a3c815a8 100644 --- a/python_modules/libraries/dagster-components/dagster_components/core/component.py +++ b/python_modules/libraries/dagster-components/dagster_components/core/component.py @@ -66,7 +66,7 @@ def build_defs(self, context: "ComponentLoadContext") -> Definitions: ... def load(cls, context: "ComponentLoadContext") -> Self: ... @classmethod - def get_metadata(cls) -> "ComponentInternalMetadata": + def get_metadata(cls) -> "ComponentTypeInternalMetadata": docstring = cls.__doc__ clean_docstring = _clean_docstring(docstring) if docstring else None @@ -104,14 +104,14 @@ def _get_click_cli_help(command: click.Command) -> str: return formatter.getvalue() -class ComponentInternalMetadata(TypedDict): +class ComponentTypeInternalMetadata(TypedDict): summary: Optional[str] description: Optional[str] generate_params_schema: Optional[Any] # json schema component_params_schema: Optional[Any] # json schema -class ComponentMetadata(ComponentInternalMetadata): +class ComponentTypeMetadata(ComponentTypeInternalMetadata): name: str package: str