From c9267862c5a967d018a430517501dba801f827c0 Mon Sep 17 00:00:00 2001 From: sbilge Date: Wed, 27 Nov 2024 13:15:06 +0000 Subject: [PATCH] mypy fix --- src/metldata/transform/base.py | 4 ++-- tests/transform/test_base.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/metldata/transform/base.py b/src/metldata/transform/base.py index e8f9222..1d24cdf 100644 --- a/src/metldata/transform/base.py +++ b/src/metldata/transform/base.py @@ -252,7 +252,7 @@ class ArtifactResource(BaseModel): ..., description="A rooted datapack describing the resource and all its dependencies.", ) - schema: SchemaPack = Field( + model: SchemaPack = Field( ..., description="A rooted schemapack describing the schema of the rooted datapack.", ) @@ -297,6 +297,6 @@ def resource_iterator(self) -> Generator[ArtifactResource, None, None]: class_name=class_name, resource_id=resource_id, datapack=rooted_datapack, - schema=rooted_schemapack, + model=rooted_schemapack, integrated=integrated_json, ) diff --git a/tests/transform/test_base.py b/tests/transform/test_base.py index 42424a7..1f42566 100644 --- a/tests/transform/test_base.py +++ b/tests/transform/test_base.py @@ -239,7 +239,7 @@ def test_workflow_artifact_resource_iterator(): observed_resources_by_class = defaultdict(set) for resource in resources: # check that the datapacks of all resources are rooted: - assert resource.class_name == resource.schema.rootClass + assert resource.class_name == resource.model.rootClass assert resource.resource_id == resource.datapack.rootResource observed_resources_by_class[resource.class_name].add(resource.resource_id)