labfreed 1.0.0a15__tar.gz → 1.0.0a17__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.
Potentially problematic release.
This version of labfreed might be problematic. Click here for more details.
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/PKG-INFO +1 -1
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/__init__.py +1 -1
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/pythonic/excel_attribute_data_source.py +30 -6
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id_resolver/resolver_config.py +1 -1
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id_resolver/resolver_config_common.py +2 -1
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/.github/workflows/pypi-publish.yml +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/.github/workflows/run-tests.yml +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/CHANGELOG.md +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/LICENSE +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/README.md +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/app_infrastructure.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/formatted_print.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/pac_info/html_renderer/external-link.svg +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/pac_info/html_renderer/macros.jinja.html +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/pac_info/html_renderer/pac-info-style.css +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/pac_info/html_renderer/pac_info.jinja.html +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/pac_info/html_renderer/pac_info_card.jinja.html +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/pac_info/pac_info.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_infrastructure.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/api_data_models/request.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/api_data_models/response.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/api_data_models/server_capabilities_response.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/client/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/client/attribute_cache.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/client/client.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/pythonic/attribute_server_factory.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/pythonic/py_attributes.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/pythonic/py_dict_data_source.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/server/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/server/attribute_data_sources.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/server/server.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/server/translation_data_sources.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/well_knonw_attribute_keys.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_cat/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_cat/category_base.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_cat/pac_cat.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_cat/predefined_categories.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id/extension.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id/id_segment.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id/pac_id.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id/url_parser.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id/url_serializer.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id_resolver/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id_resolver/cit_v1.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id_resolver/resolver.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_id_resolver/services.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/qr/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/qr/generate_qr.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/pythonic/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/pythonic/data_table.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/pythonic/pyTREX.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/pythonic/quantity.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/table_segment.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/trex.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/trex_base_models.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/trex/value_segments.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/utilities/base36.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/utilities/ensure_utc_time.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/utilities/translations.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_extensions/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_extensions/default_extension_interpreters.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_extensions/display_name_extension.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_extensions/text_base36_extension.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_extensions/trex_extension.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_keys/gs1/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_keys/gs1/gs1_ai_enum_sorted.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_keys/labfreed/well_known_keys.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_keys/unece/UneceUnits.json +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_keys/unece/__init__.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_keys/unece/unece_units.py +0 -0
- {labfreed-1.0.0a15 → labfreed-1.0.0a17}/pyproject.toml +0 -0
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
from __future__ import annotations
|
|
2
2
|
|
|
3
|
+
import logging
|
|
3
4
|
import os
|
|
4
5
|
from datetime import datetime
|
|
5
6
|
from typing import Optional, Tuple, List, Dict
|
|
@@ -133,12 +134,35 @@ class LocalExcelAttributeDataSource(_BaseExcelAttributeDataSource):
|
|
|
133
134
|
|
|
134
135
|
@cached(_cache)
|
|
135
136
|
def _read_rows_and_last_changed(self) -> Tuple[List[tuple], Optional[datetime]]:
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
137
|
+
logging.info(f"Attempting to load workbook: {self._file_path!r}")
|
|
138
|
+
|
|
139
|
+
try:
|
|
140
|
+
wb = load_workbook(
|
|
141
|
+
filename=self._file_path,
|
|
142
|
+
read_only=True,
|
|
143
|
+
data_only=True
|
|
144
|
+
)
|
|
145
|
+
ws = wb.active
|
|
146
|
+
logging.info(f"Workbook opened successfully. Active sheet: {ws.title!r}")
|
|
147
|
+
|
|
148
|
+
rows = list(ws.iter_rows(values_only=True))
|
|
149
|
+
logging.info(f"Read {len(rows)} rows from {self._file_path!r}")
|
|
150
|
+
|
|
151
|
+
last_changed = wb.properties.modified
|
|
152
|
+
logging.info(f"Workbook 'modified' property: {last_changed}")
|
|
153
|
+
|
|
154
|
+
wb.close()
|
|
155
|
+
return rows, last_changed
|
|
156
|
+
|
|
157
|
+
except FileNotFoundError:
|
|
158
|
+
logging.error(f"Workbook not found at: {self._file_path!r}", exc_info=True)
|
|
159
|
+
raise
|
|
160
|
+
except PermissionError:
|
|
161
|
+
logging.error(f"Permission denied when accessing: {self._file_path!r}", exc_info=True)
|
|
162
|
+
raise
|
|
163
|
+
except Exception as e:
|
|
164
|
+
logging.exception(f"Unexpected error reading workbook {self._file_path!r}: {e}")
|
|
165
|
+
raise
|
|
142
166
|
|
|
143
167
|
|
|
144
168
|
# # ---------------------------------------------------------------------
|
|
@@ -74,7 +74,7 @@ class ResolverConfigEntry(LabFREED_BaseModel):
|
|
|
74
74
|
|
|
75
75
|
@model_validator(mode='after')
|
|
76
76
|
def _validate_service_type(self):
|
|
77
|
-
allowed_types = [ServiceType.ATTRIBUTE_SERVICE_GENERIC.value, ServiceType.USER_HANDOVER_GENERIC.value]
|
|
77
|
+
allowed_types = [ServiceType.ATTRIBUTE_SERVICE_GENERIC.value, ServiceType.USER_HANDOVER_GENERIC.value, ServiceType.ACTION_GENERIC.value]
|
|
78
78
|
if self.service_type not in allowed_types:
|
|
79
79
|
if isinstance(self.service_type, ServiceType):
|
|
80
80
|
s= self.service_type.value
|
|
@@ -7,6 +7,7 @@ from labfreed.labfreed_infrastructure import ValidationMsgLevel, _quote_texts
|
|
|
7
7
|
class ServiceType(Enum):
|
|
8
8
|
USER_HANDOVER_GENERIC = 'userhandover-generic'
|
|
9
9
|
ATTRIBUTE_SERVICE_GENERIC = 'attributes-generic'
|
|
10
|
+
ACTION_GENERIC = "action-generic"
|
|
10
11
|
|
|
11
12
|
|
|
12
13
|
def _validate_service_name(service_name):
|
|
@@ -62,7 +63,7 @@ def _validate_service_type(service_type):
|
|
|
62
63
|
service_type= service_type.value
|
|
63
64
|
else:
|
|
64
65
|
service_type= service_type
|
|
65
|
-
allowed_types = [ServiceType.ATTRIBUTE_SERVICE_GENERIC.value, ServiceType.USER_HANDOVER_GENERIC.value]
|
|
66
|
+
allowed_types = [ServiceType.ATTRIBUTE_SERVICE_GENERIC.value, ServiceType.USER_HANDOVER_GENERIC.value, ServiceType.ACTION_GENERIC.value]
|
|
66
67
|
if service_type not in allowed_types:
|
|
67
68
|
msg_dict.append( {
|
|
68
69
|
"level": ValidationMsgLevel.ERROR,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/labfreed_extended/app/app_infrastructure.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
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/pythonic/attribute_server_factory.py
RENAMED
|
File without changes
|
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/pythonic/py_dict_data_source.py
RENAMED
|
File without changes
|
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/server/attribute_data_sources.py
RENAMED
|
File without changes
|
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/server/translation_data_sources.py
RENAMED
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/pac_attributes/well_knonw_attribute_keys.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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_extensions/display_name_extension.py
RENAMED
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_extensions/text_base36_extension.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{labfreed-1.0.0a15 → labfreed-1.0.0a17}/labfreed/well_known_keys/labfreed/well_known_keys.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|