orionis 0.375.0__py3-none-any.whl → 0.376.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.
- orionis/container/facades/facade.py +11 -2
- orionis/metadata/framework.py +1 -1
- {orionis-0.375.0.dist-info → orionis-0.376.0.dist-info}/METADATA +1 -1
- {orionis-0.375.0.dist-info → orionis-0.376.0.dist-info}/RECORD +8 -8
- {orionis-0.375.0.dist-info → orionis-0.376.0.dist-info}/WHEEL +0 -0
- {orionis-0.375.0.dist-info → orionis-0.376.0.dist-info}/licenses/LICENCE +0 -0
- {orionis-0.375.0.dist-info → orionis-0.376.0.dist-info}/top_level.txt +0 -0
- {orionis-0.375.0.dist-info → orionis-0.376.0.dist-info}/zip-safe +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
from typing import Any
|
|
2
2
|
from orionis.container.exceptions import OrionisContainerAttributeError, OrionisContainerException
|
|
3
|
-
from orionis.foundation.application import Application
|
|
3
|
+
from orionis.foundation.application import Application, IApplication
|
|
4
4
|
from typing import TypeVar, Any
|
|
5
5
|
|
|
6
6
|
T = TypeVar('T')
|
|
@@ -34,7 +34,7 @@ class FacadeMeta(type):
|
|
|
34
34
|
class Facade(metaclass=FacadeMeta):
|
|
35
35
|
|
|
36
36
|
# Application instance to resolve services
|
|
37
|
-
_app = Application()
|
|
37
|
+
_app: IApplication = Application()
|
|
38
38
|
|
|
39
39
|
@classmethod
|
|
40
40
|
def getFacadeAccessor(cls) -> str:
|
|
@@ -78,6 +78,15 @@ class Facade(metaclass=FacadeMeta):
|
|
|
78
78
|
-----
|
|
79
79
|
"""
|
|
80
80
|
|
|
81
|
+
# Ensure the application context is booted before resolving services
|
|
82
|
+
if not cls._app.isBooted:
|
|
83
|
+
raise OrionisContainerException(
|
|
84
|
+
f"Cannot resolve service '{cls.getFacadeAccessor()}' through the {cls.__name__} facade. "
|
|
85
|
+
"Facades require an active Orionis application context. "
|
|
86
|
+
"Please ensure the application is properly booted before using facades, "
|
|
87
|
+
"or access the service directly through the container."
|
|
88
|
+
)
|
|
89
|
+
|
|
81
90
|
# Get the service name from the facade accessor
|
|
82
91
|
service_name = cls.getFacadeAccessor()
|
|
83
92
|
|
orionis/metadata/framework.py
CHANGED
|
@@ -130,7 +130,7 @@ orionis/container/exceptions/exception.py,sha256=goTDEwC70xTMD2qppN8KV-xyR0Nps21
|
|
|
130
130
|
orionis/container/exceptions/type.py,sha256=cYuvoXVOgRYj3tZPfK341aUERkf33-buOiI2eXxcrAw,470
|
|
131
131
|
orionis/container/exceptions/value.py,sha256=hjY0YEusoL3DurME1ornxvIv1wyGaf6tBggLFlGHblo,472
|
|
132
132
|
orionis/container/facades/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
133
|
-
orionis/container/facades/facade.py,sha256=
|
|
133
|
+
orionis/container/facades/facade.py,sha256=wIjcQKxQa0xlTGGd6UIakenHMv0mM1BVPI7kt2Hk6uw,3724
|
|
134
134
|
orionis/container/providers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
135
135
|
orionis/container/providers/service_provider.py,sha256=9SHDzeuJbktRhrLq0zo2fZhRR4xOaYGOb2wKl7iBR4k,1923
|
|
136
136
|
orionis/container/resolver/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -247,7 +247,7 @@ orionis/foundation/providers/path_resolver_provider.py,sha256=rXvaVc5sSqmDgRzWJo
|
|
|
247
247
|
orionis/foundation/providers/progress_bar_provider.py,sha256=75Jr4iEgUOUGl8Di1DioeP5_HRQlR-1lVzPmS96sWjA,737
|
|
248
248
|
orionis/foundation/providers/workers_provider.py,sha256=WWlji3C69_-Y0c42aZDbR_bmcE_qZEh2SaA_cNkCivI,702
|
|
249
249
|
orionis/metadata/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
250
|
-
orionis/metadata/framework.py,sha256=
|
|
250
|
+
orionis/metadata/framework.py,sha256=E4M304_Fjr_Y1wVUMYUYAy92wzx1YK-WUS-ugjErQJw,4960
|
|
251
251
|
orionis/metadata/package.py,sha256=tqLfBRo-w1j_GN4xvzUNFyweWYFS-qhSgAEc-AmCH1M,5452
|
|
252
252
|
orionis/services/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
253
253
|
orionis/services/asynchrony/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -385,7 +385,7 @@ orionis/test/records/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hS
|
|
|
385
385
|
orionis/test/records/logs.py,sha256=EOQcloMVdhlNl2lU9igQz8H4b-OtKtiwh2pgr_QZWOI,13186
|
|
386
386
|
orionis/test/view/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
387
387
|
orionis/test/view/render.py,sha256=zd7xDvVfmQ2HxZamDTzL2-z2PpyL99EaolbbM7wTah4,5014
|
|
388
|
-
orionis-0.
|
|
388
|
+
orionis-0.376.0.dist-info/licenses/LICENCE,sha256=-_4cF2EBKuYVS_SQpy1uapq0oJPUU1vl_RUWSy2jJTo,1111
|
|
389
389
|
tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
390
390
|
tests/example/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
391
391
|
tests/example/test_example.py,sha256=4-L590gApSEEXj-cN2lhUDbija7EFTe1o1BKZcTv4XM,674
|
|
@@ -486,8 +486,8 @@ tests/support/wrapper/test_services_wrapper_docdict.py,sha256=nTNrvJkMSPx_aopEQ9
|
|
|
486
486
|
tests/testing/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
487
487
|
tests/testing/test_testing_result.py,sha256=fnH7hjumNSErAFGITJgq2LHxSzvPF2tdtmHL9kyAv-Y,4409
|
|
488
488
|
tests/testing/test_testing_unit.py,sha256=d3CRGo6608fMzYcZKIKapjx_af2aigqWiKSiuK9euIY,7600
|
|
489
|
-
orionis-0.
|
|
490
|
-
orionis-0.
|
|
491
|
-
orionis-0.
|
|
492
|
-
orionis-0.
|
|
493
|
-
orionis-0.
|
|
489
|
+
orionis-0.376.0.dist-info/METADATA,sha256=wcq3XUhxDeoAj-Cx1UpvYgzh7TWg9HG_hVXJkaPaKu8,4772
|
|
490
|
+
orionis-0.376.0.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
491
|
+
orionis-0.376.0.dist-info/top_level.txt,sha256=2bdoHgyGZhOtLAXS6Om8OCTmL24dUMC_L1quMe_ETbk,14
|
|
492
|
+
orionis-0.376.0.dist-info/zip-safe,sha256=frcCV1k9oG9oKj3dpUqdJg1PxRT2RSN_XKdLCPjaYaY,2
|
|
493
|
+
orionis-0.376.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|