Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions pyhelm3/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ def __init__(self, _command: Command, **kwargs):
Name = constr(pattern = r"^[a-z0-9-]+$")


#: Type for a dependency alias or name (which gets populated from alias after installation)
DependencyAliasOrName = NonEmptyString


#: Type for a SemVer version
SemVerVersion = constr(pattern = r"^v?\d+\.\d+\.\d+(-[a-zA-Z0-9\.\-]+)?(\+[a-zA-Z0-9\.\-]+)?$")

Expand All @@ -71,7 +75,7 @@ class ChartDependency(BaseModel):
"""
Model for a chart dependency.
"""
name: Name = Field(
name: DependencyAliasOrName = Field(
...,
description = "The name of the chart."
)
Expand Down Expand Up @@ -99,7 +103,7 @@ class ChartDependency(BaseModel):
"Each item can be a string or pair of child/parent sublist items."
)
)
alias: t.Optional[NonEmptyString] = Field(
alias: t.Optional[DependencyAliasOrName] = Field(
None,
description = "Alias to be used for the chart."
)
Expand Down