Skip to content
Merged
Show file tree
Hide file tree
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
2 changes: 2 additions & 0 deletions nuon/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -670,6 +670,7 @@
from .state_install_state import StateInstallState
from .state_install_state_inputs import StateInstallStateInputs
from .state_org_state import StateOrgState
from .state_partial_name import StatePartialName
from .state_runner_state import StateRunnerState
from .state_sandbox_state import StateSandboxState
from .state_sandbox_state_outputs import StateSandboxStateOutputs
Expand Down Expand Up @@ -1313,6 +1314,7 @@
"StateInstallState",
"StateInstallStateInputs",
"StateOrgState",
"StatePartialName",
"StateRunnerState",
"StateSandboxState",
"StateSandboxStateOutputs",
Expand Down
23 changes: 23 additions & 0 deletions nuon/models/app_install_state.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
from attrs import field as _attrs_field

from ..models.app_install_state_generate_source import AppInstallStateGenerateSource
from ..models.state_partial_name import StatePartialName
from ..types import UNSET, Unset

if TYPE_CHECKING:
Expand All @@ -28,6 +29,8 @@ class AppInstallState:
id (str | Unset):
install_id (str | Unset):
stale_at (GenericsNullTime | Unset):
stale_partials (list[StatePartialName] | Unset): StalePartials lists which state partials are stale and need
regeneration on next read.
triggered_by_id (str | Unset):
triggered_by_type (str | Unset):
updated_at (str | Unset):
Expand All @@ -42,6 +45,7 @@ class AppInstallState:
id: str | Unset = UNSET
install_id: str | Unset = UNSET
stale_at: GenericsNullTime | Unset = UNSET
stale_partials: list[StatePartialName] | Unset = UNSET
triggered_by_id: str | Unset = UNSET
triggered_by_type: str | Unset = UNSET
updated_at: str | Unset = UNSET
Expand Down Expand Up @@ -69,6 +73,13 @@ def to_dict(self) -> dict[str, Any]:
if not isinstance(self.stale_at, Unset):
stale_at = self.stale_at.to_dict()

stale_partials: list[str] | Unset = UNSET
if not isinstance(self.stale_partials, Unset):
stale_partials = []
for stale_partials_item_data in self.stale_partials:
stale_partials_item = stale_partials_item_data.value
stale_partials.append(stale_partials_item)

triggered_by_id = self.triggered_by_id

triggered_by_type = self.triggered_by_type
Expand Down Expand Up @@ -96,6 +107,8 @@ def to_dict(self) -> dict[str, Any]:
field_dict["install_id"] = install_id
if stale_at is not UNSET:
field_dict["stale_at"] = stale_at
if stale_partials is not UNSET:
field_dict["stale_partials"] = stale_partials
if triggered_by_id is not UNSET:
field_dict["triggered_by_id"] = triggered_by_id
if triggered_by_type is not UNSET:
Expand Down Expand Up @@ -138,6 +151,15 @@ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
else:
stale_at = GenericsNullTime.from_dict(_stale_at)

_stale_partials = d.pop("stale_partials", UNSET)
stale_partials: list[StatePartialName] | Unset = UNSET
if _stale_partials is not UNSET:
stale_partials = []
for stale_partials_item_data in _stale_partials:
stale_partials_item = StatePartialName(stale_partials_item_data)

stale_partials.append(stale_partials_item)

triggered_by_id = d.pop("triggered_by_id", UNSET)

triggered_by_type = d.pop("triggered_by_type", UNSET)
Expand All @@ -155,6 +177,7 @@ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
id=id,
install_id=install_id,
stale_at=stale_at,
stale_partials=stale_partials,
triggered_by_id=triggered_by_id,
triggered_by_type=triggered_by_type,
updated_at=updated_at,
Expand Down
18 changes: 18 additions & 0 deletions nuon/models/state_partial_name.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
from enum import Enum


class StatePartialName(str, Enum):
ACTIONS = "actions"
APP = "app"
CLOUD = "cloud"
COMPONENTS = "components"
DOMAIN = "domain"
INPUTS = "inputs"
ORG = "org"
RUNNER = "runner"
SANDBOX = "sandbox"
SECRETS = "secrets"
STACK = "stack"

def __str__(self) -> str:
return str(self.value)
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "nuon"
version = "0.19.987"
version = "0.19.988"
description = "A client library for accessing Nuon"
authors = []
requires-python = ">=3.11"
Expand Down
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.19.987
0.19.988
Loading