pypetkitapi 1.6.2__py3-none-any.whl → 1.6.3__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pypetkitapi/containers.py +2 -2
- {pypetkitapi-1.6.2.dist-info → pypetkitapi-1.6.3.dist-info}/METADATA +1 -1
- {pypetkitapi-1.6.2.dist-info → pypetkitapi-1.6.3.dist-info}/RECORD +5 -5
- {pypetkitapi-1.6.2.dist-info → pypetkitapi-1.6.3.dist-info}/LICENSE +0 -0
- {pypetkitapi-1.6.2.dist-info → pypetkitapi-1.6.3.dist-info}/WHEEL +0 -0
pypetkitapi/containers.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
"""Dataclasses container for petkit API."""
|
2
2
|
|
3
|
-
from pydantic import BaseModel, Field,
|
3
|
+
from pydantic import BaseModel, Field, root_validator
|
4
4
|
|
5
5
|
|
6
6
|
class RegionInfo(BaseModel):
|
@@ -75,7 +75,7 @@ class Pet(BaseModel):
|
|
75
75
|
device_type: str = "pet" # Fictive field (for HA compatibility) fixed
|
76
76
|
firmware: str | None = None # Fictive field (for HA compatibility) fixed
|
77
77
|
|
78
|
-
@
|
78
|
+
@root_validator(pre=True)
|
79
79
|
def populate_fictive_fields(cls, values): # noqa: N805
|
80
80
|
"""Populate fictive fields based on other fields."""
|
81
81
|
values["id"] = values.get("id") or values.get("petId")
|
@@ -2,14 +2,14 @@ pypetkitapi/__init__.py,sha256=eVpyGMD3tkYtiHUkdKEeNSZhQlZ4woI2Y5oVoV7CwXM,61
|
|
2
2
|
pypetkitapi/client.py,sha256=iLf1EZRMvuMVwtJ-1PQQ_WT6YjbDDcF--E-5gB7iM44,16716
|
3
3
|
pypetkitapi/command.py,sha256=gw3_J_oZHuuGLk66P8uRSqSrySjYa8ArpKaPHi2ybCw,7155
|
4
4
|
pypetkitapi/const.py,sha256=9XNLhM9k0GwNmWPgGef5roULpsYVZ7hzxptGgNhjs74,3432
|
5
|
-
pypetkitapi/containers.py,sha256=
|
5
|
+
pypetkitapi/containers.py,sha256=bMFx_aWWsPH824y_f2yioy0zpkZErmX3H1lN29ygL2M,4185
|
6
6
|
pypetkitapi/exceptions.py,sha256=NWmpsI2ewC4HaIeu_uFwCeuPIHIJxZBzjoCP7aNwvhs,1139
|
7
7
|
pypetkitapi/feeder_container.py,sha256=28GXZ8Nbs08PnFZZI4ENBe3UJ63gsXT3rFa151KrPxo,13310
|
8
8
|
pypetkitapi/litter_container.py,sha256=UmgIE1iYNFetHjnTXfM6jhRnOk_0Ubdyr697-6SGKqc,18042
|
9
9
|
pypetkitapi/medias.py,sha256=wutuX2w3Jz6k8F3u25Ryublf5hQtTFg1yKNNCEbtfgg,7033
|
10
10
|
pypetkitapi/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
11
11
|
pypetkitapi/water_fountain_container.py,sha256=j6FQEgbZAbsPXDVhcIB05RsNnQJftcWUJKmzuX4TrjM,6712
|
12
|
-
pypetkitapi-1.6.
|
13
|
-
pypetkitapi-1.6.
|
14
|
-
pypetkitapi-1.6.
|
15
|
-
pypetkitapi-1.6.
|
12
|
+
pypetkitapi-1.6.3.dist-info/LICENSE,sha256=4FWnKolNLc1e3w6cVlT61YxfPh0DQNeQLN1CepKKSBg,1067
|
13
|
+
pypetkitapi-1.6.3.dist-info/METADATA,sha256=kip6MkpFvs1thaG1-hSN4r1363GDimvdvFe0AoBGA3c,4636
|
14
|
+
pypetkitapi-1.6.3.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
|
15
|
+
pypetkitapi-1.6.3.dist-info/RECORD,,
|
File without changes
|
File without changes
|