Skip to content

Commit a186f28

Browse files
authored
Unfreeze models for easier testing (#1396)
1 parent 138f748 commit a186f28

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

src/wled/models.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ class Segment(BaseModel):
288288
"""
289289

290290

291-
@dataclass(frozen=True, kw_only=True)
291+
@dataclass(kw_only=True)
292292
class Leds:
293293
"""Object holding leds info from WLED."""
294294

@@ -321,7 +321,7 @@ class Leds:
321321
"""Capabilities of each segment."""
322322

323323

324-
@dataclass(frozen=True, kw_only=True)
324+
@dataclass(kw_only=True)
325325
class Wifi(BaseModel):
326326
"""Object holding Wi-Fi information from WLED.
327327
@@ -341,7 +341,7 @@ class Wifi(BaseModel):
341341
signal: int = 0
342342

343343

344-
@dataclass(frozen=True, kw_only=True)
344+
@dataclass(kw_only=True)
345345
class Filesystem(BaseModel):
346346
"""Object holding Filesystem information from WLED.
347347
@@ -433,7 +433,7 @@ class Info(BaseModel): # pylint: disable=too-many-instance-attributes
433433
ip: str = "" # pylint: disable=invalid-name
434434
"""The IP address of this instance. Empty string if not connected."""
435435

436-
leds: Leds = field(default=Leds())
436+
leds: Leds = field(default_factory=Leds)
437437
"""Contains info about the LED setup."""
438438

439439
live_ip: str = field(default="Unknown", metadata=field_options(alias="lip"))

0 commit comments

Comments
 (0)