python-eigen-ingenuity 0.5.31b1__tar.gz → 0.5.31b2__tar.gz
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.
- {python_eigen_ingenuity-0.5.31b1/python_eigen_ingenuity.egg-info → python_eigen_ingenuity-0.5.31b2}/PKG-INFO +1 -1
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/historianmulti.py +65 -49
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2/python_eigen_ingenuity.egg-info}/PKG-INFO +1 -1
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/MANIFEST.in +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/README-nocli.md +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/README.md +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/assetmodel.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/auth.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/commonmenu.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/core/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/elastic.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/events.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/historian.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/logformatter.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/settings.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/sql.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/util.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/common.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/config.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/demo.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/test_getCurrentDataPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/test_getInterpolatedPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/test_getInterpolatedRange.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/test_getMetaData.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/test_getRawDataPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/test_listDataTags.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historian/test_writePoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/common_multi.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_getClosestRawPoint.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_getCurrentDataPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_getInterpolatedPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_getInterpolatedRange.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_getMetaData.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_getRawDatapoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_listDataTags.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_tagManagement.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/historianmulti/test_writePoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/run_tests.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/assetmodelbuilder.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/assetmodelcsvwriter.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/assetmodelutilities.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/configmanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/connectors/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/connectors/boltconnector.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/connectors/dbconnectors.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/connectors/genericconnector.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/connectors/httpsconnector.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/csvcontentsmanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/csvwriter.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/fileanalyser.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/filemanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/messages.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/processors/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/processors/cypherfileprocessor.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/processors/labelmanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/processors/nodefileprocessor.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/processors/propertymanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/processors/relationshipfileprocessor.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/processors/relationshipmanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/property.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/queries/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/queries/cypherbuilder.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/queries/query.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/querymanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/versionmanager.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/pyproject.toml +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/python_eigen_ingenuity.egg-info/SOURCES.txt +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/python_eigen_ingenuity.egg-info/dependency_links.txt +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/python_eigen_ingenuity.egg-info/entry_points.txt +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/python_eigen_ingenuity.egg-info/requires.txt +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/python_eigen_ingenuity.egg-info/top_level.txt +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/common.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/common_multi.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/common.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/test_getCurrentDataPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/test_getInterpolatedPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/test_getInterpolatedRange.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/test_getMetaData.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/test_getRawDataPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/test_listDataTags.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian/test_writePoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/__init__.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/common_multi.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_getClosestRawPoint.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_getCurrentDataPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_getInterpolatedPoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_getInterpolatedRange.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_getMetaData.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_getRawDatapoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_listDataTags.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_tagManagement.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/eigeningenuity/historian-multi/test_writePoints.py +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/requirements.txt +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/setup.cfg +0 -0
- {python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/setup.py +0 -0
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/historianmulti.py
RENAMED
|
@@ -17,22 +17,23 @@ eigeningenuity.core) or a full URL to a JSON Bridge Historian instance.
|
|
|
17
17
|
print(asctime(time.gmtime(dp['timestamp'])), dp['value'])
|
|
18
18
|
"""
|
|
19
19
|
|
|
20
|
-
import requests
|
|
21
20
|
import re
|
|
22
|
-
from typing import Union
|
|
23
21
|
from datetime import datetime
|
|
22
|
+
from typing import Union
|
|
23
|
+
from urllib.error import URLError
|
|
24
24
|
|
|
25
|
+
import requests
|
|
25
26
|
from requests.exceptions import ConnectionError
|
|
26
|
-
|
|
27
|
-
from eigeningenuity.core import
|
|
27
|
+
|
|
28
|
+
from eigeningenuity.core import EigenServer, get_default_server
|
|
28
29
|
from eigeningenuity.util import (
|
|
29
|
-
force_list,
|
|
30
|
-
time_to_epoch_millis,
|
|
31
30
|
EigenException,
|
|
32
|
-
merge_tags_from_response,
|
|
33
|
-
update_keys,
|
|
34
31
|
_do_historian_multi_request,
|
|
32
|
+
force_list,
|
|
35
33
|
format_output,
|
|
34
|
+
merge_tags_from_response,
|
|
35
|
+
time_to_epoch_millis,
|
|
36
|
+
update_keys,
|
|
36
37
|
)
|
|
37
38
|
|
|
38
39
|
|
|
@@ -88,7 +89,7 @@ class HistorianMulti(object):
|
|
|
88
89
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
89
90
|
RuntimeError: If no response is received from the API.
|
|
90
91
|
HTTPError: If the API request fails.
|
|
91
|
-
|
|
92
|
+
|
|
92
93
|
Docs:
|
|
93
94
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/reading-data/getcurrentdatapoints
|
|
94
95
|
"""
|
|
@@ -132,7 +133,7 @@ class HistorianMulti(object):
|
|
|
132
133
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
133
134
|
RuntimeError: If no response is received from the API.
|
|
134
135
|
HTTPError: If the API request fails.
|
|
135
|
-
|
|
136
|
+
|
|
136
137
|
Docs:
|
|
137
138
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/reading-data/getinterpolatedpoints
|
|
138
139
|
"""
|
|
@@ -188,7 +189,7 @@ class HistorianMulti(object):
|
|
|
188
189
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
189
190
|
RuntimeError: If no response is received from the API.
|
|
190
191
|
HTTPError: If the API request fails.
|
|
191
|
-
|
|
192
|
+
|
|
192
193
|
Docs:
|
|
193
194
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/reading-data/getinterpolatedrange
|
|
194
195
|
"""
|
|
@@ -245,7 +246,7 @@ class HistorianMulti(object):
|
|
|
245
246
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
246
247
|
RuntimeError: If no response is received from the API.
|
|
247
248
|
HTTPError: If the API request fails.
|
|
248
|
-
|
|
249
|
+
|
|
249
250
|
Docs:
|
|
250
251
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/reading-data/getrawdatapoints
|
|
251
252
|
"""
|
|
@@ -285,24 +286,24 @@ class HistorianMulti(object):
|
|
|
285
286
|
):
|
|
286
287
|
"""Get the closest raw point to one or more timestamps.
|
|
287
288
|
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
289
|
+
Args:
|
|
290
|
+
tags (Union[str, list]): Tag name or list of tags to query.
|
|
291
|
+
timestamps (Union[int, float, str, datetime, list]): One or more timestamps to find closest raw points for.
|
|
292
|
+
before_or_after (str, optional): Selection rule for closest point. Defaults to "AFTER_OR_AT".
|
|
293
|
+
output (str, optional): Output format selector. Accepts "json", "df", "raw", "string". Defaults to "json".
|
|
294
|
+
|
|
295
|
+
Returns:
|
|
296
|
+
dict|list|pandas.DataFrame|str: Closest raw points to the timestamps. Format depends on output parameter.
|
|
297
|
+
|
|
298
|
+
Raises:
|
|
299
|
+
ValueError: When invalid Output Type is given
|
|
300
|
+
URLError: If no Ingenuity instance can be reached or no internet connection is available.
|
|
301
|
+
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
302
|
+
RuntimeError: If no response is received from the API.
|
|
303
|
+
HTTPError: If the API request fails.
|
|
304
|
+
|
|
305
|
+
Docs:
|
|
306
|
+
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/reading-data/getclosestrawpoint
|
|
306
307
|
"""
|
|
307
308
|
before_or_after = before_or_after.upper()
|
|
308
309
|
|
|
@@ -374,7 +375,7 @@ class HistorianMulti(object):
|
|
|
374
375
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
375
376
|
RuntimeError: If no response is received from the API.
|
|
376
377
|
HTTPError: If the API request fails.
|
|
377
|
-
|
|
378
|
+
|
|
378
379
|
Docs:
|
|
379
380
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/reading-data/getaggregates
|
|
380
381
|
"""
|
|
@@ -465,7 +466,7 @@ class HistorianMulti(object):
|
|
|
465
466
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
466
467
|
RuntimeError: If no response is received from the API.
|
|
467
468
|
HTTPError: If the API request fails.
|
|
468
|
-
|
|
469
|
+
|
|
469
470
|
Docs:
|
|
470
471
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/reading-data/getaggregateintervals
|
|
471
472
|
"""
|
|
@@ -549,7 +550,7 @@ class HistorianMulti(object):
|
|
|
549
550
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
550
551
|
RuntimeError: If no response is received from the API.
|
|
551
552
|
HTTPError: If the API request fails.
|
|
552
|
-
|
|
553
|
+
|
|
553
554
|
Docs:
|
|
554
555
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/metadata/listdatatags
|
|
555
556
|
"""
|
|
@@ -559,14 +560,20 @@ class HistorianMulti(object):
|
|
|
559
560
|
|
|
560
561
|
return tags
|
|
561
562
|
|
|
562
|
-
def getMetaData(
|
|
563
|
+
def getMetaData(
|
|
564
|
+
self,
|
|
565
|
+
historian: str = None,
|
|
566
|
+
limit: int = 100,
|
|
567
|
+
match: str = "",
|
|
568
|
+
output: str = "json",
|
|
569
|
+
):
|
|
563
570
|
"""Fetch tag metadata for a historian, optionally filtered with a wildcard.
|
|
564
571
|
|
|
565
572
|
Args:
|
|
566
573
|
historian (str, optional): Historian name to search.
|
|
567
574
|
limit (int, optional): Max number of tags returned. Defaults to 100.
|
|
568
575
|
match (str, optional): Wildcard pattern for tag names. Defaults to "".
|
|
569
|
-
|
|
576
|
+
output (str, optional): Output format selector. Accepts "json", "raw". Defaults to "json".
|
|
570
577
|
Returns:
|
|
571
578
|
list[dict]: List of metadata dictionaries for each tag.
|
|
572
579
|
|
|
@@ -575,12 +582,16 @@ class HistorianMulti(object):
|
|
|
575
582
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
576
583
|
RuntimeError: If no response is received from the API.
|
|
577
584
|
HTTPError: If the API request fails.
|
|
578
|
-
|
|
585
|
+
|
|
579
586
|
Docs:
|
|
580
587
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/metadata/getmetadata
|
|
581
588
|
"""
|
|
582
|
-
if historian
|
|
583
|
-
|
|
589
|
+
if "/" in historian and match == "":
|
|
590
|
+
split_hist = historian.split("/")
|
|
591
|
+
match = split_hist[1]
|
|
592
|
+
historian = split_hist[0]
|
|
593
|
+
elif historian is None:
|
|
594
|
+
historian = self.historian[0:-1]
|
|
584
595
|
|
|
585
596
|
resp = _do_historian_multi_request(
|
|
586
597
|
self.searchurl + f"?historian={historian}&limit={limit}&search={match}",
|
|
@@ -590,7 +601,12 @@ class HistorianMulti(object):
|
|
|
590
601
|
)
|
|
591
602
|
metadata = resp["tags"]
|
|
592
603
|
|
|
593
|
-
|
|
604
|
+
if output == "raw":
|
|
605
|
+
return metadata
|
|
606
|
+
elif output == "json":
|
|
607
|
+
return {tag["tagName"]: tag for tag in metadata}
|
|
608
|
+
else:
|
|
609
|
+
raise ValueError(f"Invalid output format: {output}")
|
|
594
610
|
|
|
595
611
|
def listHistorians(self, writable):
|
|
596
612
|
"""Retrieve all historians available on the Ingenuity instance.
|
|
@@ -608,7 +624,7 @@ class HistorianMulti(object):
|
|
|
608
624
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
609
625
|
RuntimeError: If no response is received from the API.
|
|
610
626
|
HTTPError: If the API request fails.
|
|
611
|
-
|
|
627
|
+
|
|
612
628
|
Docs:
|
|
613
629
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/metadata/listhistorians
|
|
614
630
|
"""
|
|
@@ -619,9 +635,9 @@ class HistorianMulti(object):
|
|
|
619
635
|
self.auth,
|
|
620
636
|
get_request=True,
|
|
621
637
|
)
|
|
622
|
-
|
|
638
|
+
|
|
623
639
|
historians = resp["historians"]
|
|
624
|
-
|
|
640
|
+
|
|
625
641
|
metadata = [x["name"] for x in historians]
|
|
626
642
|
|
|
627
643
|
return metadata
|
|
@@ -651,7 +667,7 @@ class HistorianMulti(object):
|
|
|
651
667
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
652
668
|
RuntimeError: If no response is received from the API.
|
|
653
669
|
HTTPError: If the API request fails.
|
|
654
|
-
|
|
670
|
+
|
|
655
671
|
Docs:
|
|
656
672
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/metadata/createtag
|
|
657
673
|
"""
|
|
@@ -706,7 +722,7 @@ class HistorianMulti(object):
|
|
|
706
722
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
707
723
|
RuntimeError: If no response is received from the API.
|
|
708
724
|
HTTPError: If the API request fails.
|
|
709
|
-
|
|
725
|
+
|
|
710
726
|
Docs:
|
|
711
727
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/metadata/updatetag
|
|
712
728
|
"""
|
|
@@ -763,7 +779,7 @@ class HistorianMulti(object):
|
|
|
763
779
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
764
780
|
RuntimeError: If no response is received from the API.
|
|
765
781
|
HTTPError: If the API request fails.
|
|
766
|
-
|
|
782
|
+
|
|
767
783
|
Docs:
|
|
768
784
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/writing-data/createandpopulatetag
|
|
769
785
|
"""
|
|
@@ -823,7 +839,7 @@ class HistorianMulti(object):
|
|
|
823
839
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
824
840
|
RuntimeError: If no response is received from the API.
|
|
825
841
|
HTTPError: If the API request fails.
|
|
826
|
-
|
|
842
|
+
|
|
827
843
|
Docs:
|
|
828
844
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/writing-data/writepoints
|
|
829
845
|
"""
|
|
@@ -861,7 +877,7 @@ class HistorianMulti(object):
|
|
|
861
877
|
RemoteServerException: If the historian cannot be found or the API returns an error.
|
|
862
878
|
RuntimeError: If no response is received from the API.
|
|
863
879
|
HTTPError: If the API request fails.
|
|
864
|
-
|
|
880
|
+
|
|
865
881
|
Docs:
|
|
866
882
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/writing-data/writepointsbatch
|
|
867
883
|
"""
|
|
@@ -916,7 +932,7 @@ def createPoint(
|
|
|
916
932
|
|
|
917
933
|
Raises:
|
|
918
934
|
EigenException: If status is not "OK" or "BAD".
|
|
919
|
-
|
|
935
|
+
|
|
920
936
|
Docs:
|
|
921
937
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/writing-data/createpoint
|
|
922
938
|
"""
|
|
@@ -937,7 +953,7 @@ def get_historian_multi(
|
|
|
937
953
|
|
|
938
954
|
Returns:
|
|
939
955
|
HistorianMulti: An object that can be used to query historian data.
|
|
940
|
-
|
|
956
|
+
|
|
941
957
|
Docs:
|
|
942
958
|
https://docs.eigeningenuity.co/developing-with-eigen/python-library/historian-multi/get_historian_multi
|
|
943
959
|
"""
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/__init__.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/assetmodel.py
RENAMED
|
File without changes
|
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/commonmenu.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/core/__init__.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/elastic.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/events.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/historian.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/logformatter.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/eigeningenuity/settings.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/local-tests/run_tests.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/__init__.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/csvwriter.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/fileanalyser.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/filemanager.py
RENAMED
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/messages.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/property.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/modelbuilder/src/querymanager.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{python_eigen_ingenuity-0.5.31b1 → python_eigen_ingenuity-0.5.31b2}/regressiontests/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|