oarepo-runtime 1.5.136__py3-none-any.whl → 1.6.0__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.
- oarepo_runtime/config.py +15 -0
- {oarepo_runtime-1.5.136.dist-info → oarepo_runtime-1.6.0.dist-info}/METADATA +1 -1
- {oarepo_runtime-1.5.136.dist-info → oarepo_runtime-1.6.0.dist-info}/RECORD +7 -6
- {oarepo_runtime-1.5.136.dist-info → oarepo_runtime-1.6.0.dist-info}/WHEEL +0 -0
- {oarepo_runtime-1.5.136.dist-info → oarepo_runtime-1.6.0.dist-info}/entry_points.txt +0 -0
- {oarepo_runtime-1.5.136.dist-info → oarepo_runtime-1.6.0.dist-info}/licenses/LICENSE +0 -0
- {oarepo_runtime-1.5.136.dist-info → oarepo_runtime-1.6.0.dist-info}/top_level.txt +0 -0
oarepo_runtime/config.py
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
from typing import cast
|
2
|
+
|
3
|
+
from flask import Flask
|
4
|
+
|
5
|
+
|
6
|
+
def build_config[T: type](config_class: T, app: Flask) -> T:
|
7
|
+
"""
|
8
|
+
Builds the configuration for the service
|
9
|
+
|
10
|
+
This function is used to build the configuration for the service
|
11
|
+
"""
|
12
|
+
if hasattr(config_class, "build") and callable(config_class.build):
|
13
|
+
return cast(T, config_class.build(app))
|
14
|
+
else:
|
15
|
+
return config_class()
|
@@ -1,4 +1,5 @@
|
|
1
1
|
oarepo_runtime/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
2
|
+
oarepo_runtime/config.py,sha256=n9ZEDL0kKd1AkrQUJ-dl0iekUJJienppDI2gYPkfK6Q,403
|
2
3
|
oarepo_runtime/ext.py,sha256=6w6bpTpNjjj3txgVu0nfpmPa9CnDS6Zl6U2DCNs9Usc,2565
|
3
4
|
oarepo_runtime/ext_config.py,sha256=ERpi6uJqDE6OpqebB_vuusmoB3xaAziuKeGVxVI5Q-w,2155
|
4
5
|
oarepo_runtime/profile.py,sha256=QzrQoZncjoN74ZZnpkEKakNk08KCzBU7m6y42RN8AMY,1637
|
@@ -148,13 +149,13 @@ oarepo_runtime/translations/en/LC_MESSAGES/messages.po,sha256=7-5S3iINOSFSI5gVdR
|
|
148
149
|
oarepo_runtime/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
149
150
|
oarepo_runtime/utils/functools.py,sha256=gKS9YZtlIYcDvdNA9cmYO00yjiXBYV1jg8VpcRUyQyg,1324
|
150
151
|
oarepo_runtime/utils/path.py,sha256=V1NVyk3m12_YLbj7QHYvUpE1wScO78bYsX1LOLeXDkI,3108
|
151
|
-
oarepo_runtime-1.
|
152
|
+
oarepo_runtime-1.6.0.dist-info/licenses/LICENSE,sha256=h2uWz0OaB3EN-J1ImdGJZzc7yvfQjvHVYdUhQ-H7ypY,1064
|
152
153
|
tests/marshmallow_to_json/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
153
154
|
tests/marshmallow_to_json/test_datacite_ui_schema.py,sha256=82iLj8nW45lZOUewpWbLX3mpSkpa9lxo-vK-Qtv_1bU,48552
|
154
155
|
tests/marshmallow_to_json/test_simple_schema.py,sha256=izZN9p0v6kovtSZ6AdxBYmK_c6ZOti2_z_wPT_zXIr0,1500
|
155
156
|
tests/pkg_data/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
156
|
-
oarepo_runtime-1.
|
157
|
-
oarepo_runtime-1.
|
158
|
-
oarepo_runtime-1.
|
159
|
-
oarepo_runtime-1.
|
160
|
-
oarepo_runtime-1.
|
157
|
+
oarepo_runtime-1.6.0.dist-info/METADATA,sha256=WIPIVNqe7zXtEAYSQEBCbFLsYhiuadkxiw4Yymximzs,4741
|
158
|
+
oarepo_runtime-1.6.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
159
|
+
oarepo_runtime-1.6.0.dist-info/entry_points.txt,sha256=k7O5LZUOGsVeSpB7ulU0txBUNp1CVQG7Q7TJIVTPbzU,491
|
160
|
+
oarepo_runtime-1.6.0.dist-info/top_level.txt,sha256=bHhlkT1_RQC4IkfTQCqA3iN4KCB6cSFQlsXpQMSP-bE,21
|
161
|
+
oarepo_runtime-1.6.0.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|