Skip to content

Commit

Permalink
rename
Browse files Browse the repository at this point in the history
  • Loading branch information
avishniakov committed Aug 27, 2024
1 parent 0152dc4 commit feb6028
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions src/zenml/zen_stores/schemas/model_schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -287,10 +287,10 @@ class ModelVersionSchema(NamedSchema, table=True):
),
)
pipeline_runs: List["PipelineRunSchema"] = Relationship(
back_populates="configured_model_version"
back_populates="model_version"
)
step_runs: List["StepRunSchema"] = Relationship(
back_populates="configured_model_version"
back_populates="model_version"
)

# TODO: In Pydantic v2, the `model_` is a protected namespaces for all
Expand Down
6 changes: 3 additions & 3 deletions src/zenml/zen_stores/schemas/pipeline_run_schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ class PipelineRunSchema(NamedSchema, table=True):
step_runs: List["StepRunSchema"] = Relationship(
sa_relationship_kwargs={"cascade": "delete"},
)
configured_model_version: "ModelVersionSchema" = Relationship(
model_version: "ModelVersionSchema" = Relationship(
back_populates="pipeline_runs",
)

Expand Down Expand Up @@ -348,8 +348,8 @@ def to_model(
resources = None
if include_resources:
model_version = None
if self.configured_model_version:
model_version = self.configured_model_version.to_model()
if self.model_version:
model_version = self.model_version.to_model()

resources = PipelineRunResponseResources(
model_version=model_version,
Expand Down
6 changes: 3 additions & 3 deletions src/zenml/zen_stores/schemas/step_run_schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ class StepRunSchema(NamedSchema, table=True):
"primaryjoin": "StepRunParentsSchema.child_id == StepRunSchema.id",
},
)
configured_model_version: "ModelVersionSchema" = Relationship(
model_version: "ModelVersionSchema" = Relationship(
back_populates="step_runs",
)

Expand Down Expand Up @@ -288,8 +288,8 @@ def to_model(
resources = None
if include_resources:
model_version = None
if self.configured_model_version:
model_version = self.configured_model_version.to_model()
if self.model_version:
model_version = self.model_version.to_model()

resources = StepRunResponseResources(model_version=model_version)

Expand Down

0 comments on commit feb6028

Please sign in to comment.