Coverage for opt/mealie/lib/python3.12/site-packages/mealie/schema/recipe/recipe_step.py: 100%

13 statements  

« prev     ^ index     » next       coverage.py v7.15.2, created at 2026-10-07 03:04 +0000

1from uuid import UUID, uuid4 

2 

3from pydantic import UUID4, ConfigDict, Field 

4 

5from mealie.schema._mealie import MealieModel 

6 

7 

8class IngredientReferences(MealieModel): 

9 """ 

10 A list of ingredient references. 

11 """ 

12 

13 reference_id: UUID4 | None = None 

14 model_config = ConfigDict(from_attributes=True) 

15 

16 

17class RecipeStep(MealieModel): 

18 id: UUID | None = Field(default_factory=uuid4) 

19 title: str | None = "" # This is the section title!!! 

20 summary: str | None = "" 

21 text: str 

22 ingredient_references: list[IngredientReferences] = [] 

23 model_config = ConfigDict(from_attributes=True)