DLMS-SPODES-client 0.19.22__py3-none-any.whl → 0.19.23__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.
- DLMS_SPODES_client/FCS16.py +39 -39
- DLMS_SPODES_client/__init__.py +12 -12
- DLMS_SPODES_client/client.py +2091 -2091
- DLMS_SPODES_client/gurux_common/enums/TraceLevel.py +21 -21
- DLMS_SPODES_client/gurux_dlms/AesGcmParameter.py +37 -37
- DLMS_SPODES_client/gurux_dlms/CountType.py +16 -16
- DLMS_SPODES_client/gurux_dlms/GXByteBuffer.py +545 -545
- DLMS_SPODES_client/gurux_dlms/GXCiphering.py +196 -196
- DLMS_SPODES_client/gurux_dlms/GXDLMS.py +426 -426
- DLMS_SPODES_client/gurux_dlms/GXDLMSChippering.py +237 -237
- DLMS_SPODES_client/gurux_dlms/GXDLMSChipperingStream.py +977 -977
- DLMS_SPODES_client/gurux_dlms/GXDLMSConfirmedServiceError.py +90 -90
- DLMS_SPODES_client/gurux_dlms/GXDLMSException.py +139 -139
- DLMS_SPODES_client/gurux_dlms/GXDLMSLNParameters.py +33 -33
- DLMS_SPODES_client/gurux_dlms/GXDLMSSNParameters.py +21 -21
- DLMS_SPODES_client/gurux_dlms/GXDLMSSettings.py +254 -254
- DLMS_SPODES_client/gurux_dlms/GXReplyData.py +87 -87
- DLMS_SPODES_client/gurux_dlms/HdlcControlFrame.py +9 -9
- DLMS_SPODES_client/gurux_dlms/MBusCommand.py +8 -8
- DLMS_SPODES_client/gurux_dlms/MBusEncryptionMode.py +27 -27
- DLMS_SPODES_client/gurux_dlms/ResponseType.py +8 -8
- DLMS_SPODES_client/gurux_dlms/SetResponseType.py +29 -29
- DLMS_SPODES_client/gurux_dlms/_HDLCInfo.py +9 -9
- DLMS_SPODES_client/gurux_dlms/__init__.py +75 -75
- DLMS_SPODES_client/gurux_dlms/enums/Access.py +12 -12
- DLMS_SPODES_client/gurux_dlms/enums/ApplicationReference.py +14 -14
- DLMS_SPODES_client/gurux_dlms/enums/Authentication.py +41 -41
- DLMS_SPODES_client/gurux_dlms/enums/BerType.py +35 -35
- DLMS_SPODES_client/gurux_dlms/enums/Command.py +285 -285
- DLMS_SPODES_client/gurux_dlms/enums/Definition.py +9 -9
- DLMS_SPODES_client/gurux_dlms/enums/ErrorCode.py +46 -46
- DLMS_SPODES_client/gurux_dlms/enums/ExceptionServiceError.py +12 -12
- DLMS_SPODES_client/gurux_dlms/enums/HardwareResource.py +10 -10
- DLMS_SPODES_client/gurux_dlms/enums/HdlcFrameType.py +9 -9
- DLMS_SPODES_client/gurux_dlms/enums/Initiate.py +10 -10
- DLMS_SPODES_client/gurux_dlms/enums/LoadDataSet.py +13 -13
- DLMS_SPODES_client/gurux_dlms/enums/ObjectType.py +306 -306
- DLMS_SPODES_client/gurux_dlms/enums/Priority.py +7 -7
- DLMS_SPODES_client/gurux_dlms/enums/RequestTypes.py +9 -9
- DLMS_SPODES_client/gurux_dlms/enums/Security.py +14 -14
- DLMS_SPODES_client/gurux_dlms/enums/Service.py +16 -16
- DLMS_SPODES_client/gurux_dlms/enums/ServiceClass.py +9 -9
- DLMS_SPODES_client/gurux_dlms/enums/ServiceError.py +8 -8
- DLMS_SPODES_client/gurux_dlms/enums/Standard.py +18 -18
- DLMS_SPODES_client/gurux_dlms/enums/StateError.py +7 -7
- DLMS_SPODES_client/gurux_dlms/enums/Task.py +10 -10
- DLMS_SPODES_client/gurux_dlms/enums/VdeStateError.py +10 -10
- DLMS_SPODES_client/gurux_dlms/enums/__init__.py +33 -33
- DLMS_SPODES_client/gurux_dlms/internal/_GXCommon.py +1673 -1673
- DLMS_SPODES_client/logger.py +56 -56
- DLMS_SPODES_client/services.py +97 -97
- DLMS_SPODES_client/session.py +365 -365
- DLMS_SPODES_client/settings.py +48 -48
- DLMS_SPODES_client/task.py +1842 -1842
- {dlms_spodes_client-0.19.22.dist-info → dlms_spodes_client-0.19.23.dist-info}/METADATA +29 -27
- dlms_spodes_client-0.19.23.dist-info/RECORD +61 -0
- dlms_spodes_client-0.19.22.dist-info/RECORD +0 -61
- {dlms_spodes_client-0.19.22.dist-info → dlms_spodes_client-0.19.23.dist-info}/WHEEL +0 -0
- {dlms_spodes_client-0.19.22.dist-info → dlms_spodes_client-0.19.23.dist-info}/entry_points.txt +0 -0
- {dlms_spodes_client-0.19.22.dist-info → dlms_spodes_client-0.19.23.dist-info}/top_level.txt +0 -0
DLMS_SPODES_client/settings.py
CHANGED
|
@@ -1,48 +1,48 @@
|
|
|
1
|
-
from typing import Literal
|
|
2
|
-
from pydantic import BaseModel, Field, ConfigDict, ValidationError, field_serializer
|
|
3
|
-
from DLMS_SPODES.settings import toml_data
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
class Worker(BaseModel):
|
|
7
|
-
run: bool = Field(default=False, title="auto running")
|
|
8
|
-
time_checking: float = Field(default=1.0, title="time checking")
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
class Storage(BaseModel):
|
|
12
|
-
persistent_depth: int = Field(default=1000, title="persistent depth")
|
|
13
|
-
volatile_depth: int = Field(default=100, title="volatile depth")
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
class Session(BaseModel):
|
|
17
|
-
result_storage: Storage = Field(default_factory=Storage, title="result storage")
|
|
18
|
-
work_storage: Storage = Field(
|
|
19
|
-
default=Storage(
|
|
20
|
-
persistent_depth=100,
|
|
21
|
-
volatile_depth=10),
|
|
22
|
-
title="work storage")
|
|
23
|
-
worker: Worker = Field(default_factory=Worker, title="Рабочий")
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
class HeaderNamesCSV(BaseModel):
|
|
27
|
-
secret: list[str] = Field(default=["secret"])
|
|
28
|
-
ip: list[str] = Field(default=["ip"])
|
|
29
|
-
name: list[str] = Field(default=["name"])
|
|
30
|
-
port: list[str] = Field(default=["port"])
|
|
31
|
-
m_id: list[str] = Field(default=["m_id"])
|
|
32
|
-
sap: list[str] = Field(default=["sap"])
|
|
33
|
-
da: list[str] = Field(default=["da"])
|
|
34
|
-
timeout: list[str] = Field(default=["timeout"])
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
class CSV(BaseModel):
|
|
38
|
-
header_names: HeaderNamesCSV = Field(default_factory=HeaderNamesCSV)
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
class Settings(BaseModel):
|
|
42
|
-
session: Session = Field(default_factory=Session, title="Session")
|
|
43
|
-
from_csv: CSV = Field(default_factory=CSV, title="from CSV")
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
data = toml_data.get("DLMSClient", {})
|
|
47
|
-
settings = Settings(**data)
|
|
48
|
-
print(settings)
|
|
1
|
+
from typing import Literal
|
|
2
|
+
from pydantic import BaseModel, Field, ConfigDict, ValidationError, field_serializer
|
|
3
|
+
from DLMS_SPODES.settings import toml_data
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class Worker(BaseModel):
|
|
7
|
+
run: bool = Field(default=False, title="auto running")
|
|
8
|
+
time_checking: float = Field(default=1.0, title="time checking")
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class Storage(BaseModel):
|
|
12
|
+
persistent_depth: int = Field(default=1000, title="persistent depth")
|
|
13
|
+
volatile_depth: int = Field(default=100, title="volatile depth")
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class Session(BaseModel):
|
|
17
|
+
result_storage: Storage = Field(default_factory=Storage, title="result storage")
|
|
18
|
+
work_storage: Storage = Field(
|
|
19
|
+
default=Storage(
|
|
20
|
+
persistent_depth=100,
|
|
21
|
+
volatile_depth=10),
|
|
22
|
+
title="work storage")
|
|
23
|
+
worker: Worker = Field(default_factory=Worker, title="Рабочий")
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class HeaderNamesCSV(BaseModel):
|
|
27
|
+
secret: list[str] = Field(default=["secret"])
|
|
28
|
+
ip: list[str] = Field(default=["ip"])
|
|
29
|
+
name: list[str] = Field(default=["name"])
|
|
30
|
+
port: list[str] = Field(default=["port"])
|
|
31
|
+
m_id: list[str] = Field(default=["m_id"])
|
|
32
|
+
sap: list[str] = Field(default=["sap"])
|
|
33
|
+
da: list[str] = Field(default=["da"])
|
|
34
|
+
timeout: list[str] = Field(default=["timeout"])
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
class CSV(BaseModel):
|
|
38
|
+
header_names: HeaderNamesCSV = Field(default_factory=HeaderNamesCSV)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
class Settings(BaseModel):
|
|
42
|
+
session: Session = Field(default_factory=Session, title="Session")
|
|
43
|
+
from_csv: CSV = Field(default_factory=CSV, title="from CSV")
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
data = toml_data.get("DLMSClient", {})
|
|
47
|
+
settings = Settings(**data)
|
|
48
|
+
print(settings)
|