Skip to content

Commit

Permalink
fix(roof): Ensure that RoofSpecification has at least one geometry
Browse files Browse the repository at this point in the history
  • Loading branch information
chriswmackey committed Sep 24, 2024
1 parent 3908cf2 commit bbbb669
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions dragonfly_schema/roof.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
"""Geometry for specifying sloped roofs over a Story."""
from pydantic import Field, constr
from typing import List
from pydantic import Field, constr, conlist

from honeybee_schema._base import NoExtraBaseModel
from honeybee_schema.model import Face3D
Expand All @@ -11,7 +10,7 @@ class RoofSpecification(NoExtraBaseModel):

type: constr(regex='^RoofSpecification$') = 'RoofSpecification'

geometry: List[Face3D] = Field(
geometry: conlist(Face3D, min_items=1) = Field(
...,
description='An array of Face3D objects representing the geometry of the '
'Roof. None of these geometries should overlap in plan and, together, these '
Expand Down

0 comments on commit bbbb669

Please sign in to comment.