maleo-foundation 0.0.76__tar.gz → 0.0.78__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.
Files changed (65) hide show
  1. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/PKG-INFO +1 -1
  2. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/general/http.py +12 -3
  3. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/types.py +1 -0
  4. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/utils/controller.py +2 -2
  5. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation.egg-info/PKG-INFO +1 -1
  6. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/pyproject.toml +1 -1
  7. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/README.md +0 -0
  8. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/__init__.py +0 -0
  9. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/__init__.py +0 -0
  10. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/general/__init__.py +0 -0
  11. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/google/__init__.py +0 -0
  12. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/google/cloud/__init__.py +0 -0
  13. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/google/cloud/logging.py +0 -0
  14. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/google/cloud/secret.py +0 -0
  15. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/google/cloud/storage.py +0 -0
  16. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/utils/__init__.py +0 -0
  17. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/clients/utils/logger.py +0 -0
  18. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/constants.py +0 -0
  19. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/db/__init__.py +0 -0
  20. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/db/engine.py +0 -0
  21. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/db/manager.py +0 -0
  22. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/db/session.py +0 -0
  23. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/db/table.py +0 -0
  24. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/enums.py +0 -0
  25. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/expanded_types/__init__.py +0 -0
  26. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/expanded_types/client.py +0 -0
  27. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/expanded_types/general.py +0 -0
  28. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/expanded_types/query.py +0 -0
  29. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/expanded_types/service.py +0 -0
  30. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/extended_types.py +0 -0
  31. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/middlewares/__init__.py +0 -0
  32. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/middlewares/base.py +0 -0
  33. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/middlewares/cors.py +0 -0
  34. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/__init__.py +0 -0
  35. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/responses.py +0 -0
  36. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/schemas/__init__.py +0 -0
  37. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/schemas/general.py +0 -0
  38. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/schemas/parameter.py +0 -0
  39. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/schemas/result.py +0 -0
  40. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/__init__.py +0 -0
  41. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/parameters/__init__.py +0 -0
  42. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/parameters/client.py +0 -0
  43. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/parameters/general.py +0 -0
  44. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/parameters/service.py +0 -0
  45. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/__init__.py +0 -0
  46. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/client/__init__.py +0 -0
  47. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/client/controllers/__init__.py +0 -0
  48. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/client/controllers/http.py +0 -0
  49. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/client/service.py +0 -0
  50. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/service/__init__.py +0 -0
  51. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/service/controllers/__init__.py +0 -0
  52. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/service/controllers/rest.py +0 -0
  53. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/service/general.py +0 -0
  54. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/models/transfers/results/service/query.py +0 -0
  55. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/utils/__init__.py +0 -0
  56. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/utils/exceptions.py +0 -0
  57. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/utils/formatter/__init__.py +0 -0
  58. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/utils/formatter/case.py +0 -0
  59. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/utils/logger.py +0 -0
  60. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation/utils/query.py +0 -0
  61. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation.egg-info/SOURCES.txt +0 -0
  62. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation.egg-info/dependency_links.txt +0 -0
  63. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation.egg-info/requires.txt +0 -0
  64. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/maleo_foundation.egg-info/top_level.txt +0 -0
  65. {maleo_foundation-0.0.76 → maleo_foundation-0.0.78}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: maleo_foundation
3
- Version: 0.0.76
3
+ Version: 0.0.78
4
4
  Summary: Foundation package for Maleo
5
5
  Author-email: Agra Bima Yuda <agra@nexmedis.com>
6
6
  License: MIT
@@ -4,6 +4,7 @@ from typing import AsyncGenerator, Optional
4
4
 
5
5
  class HTTPClientManager:
6
6
  client:Optional[httpx.AsyncClient] = None
7
+ base_url:Optional[str] = None
7
8
 
8
9
  @classmethod
9
10
  def initialize(cls) -> None:
@@ -20,12 +21,12 @@ class HTTPClientManager:
20
21
  yield cls.client
21
22
 
22
23
  @classmethod
23
- async def inject(cls) -> AsyncGenerator[httpx.AsyncClient, None]:
24
+ async def inject_client(cls) -> AsyncGenerator[httpx.AsyncClient, None]:
24
25
  return cls._client_handler()
25
26
 
26
27
  @classmethod
27
28
  @asynccontextmanager
28
- async def get(cls) -> AsyncGenerator[httpx.AsyncClient, None]:
29
+ async def get_client(cls) -> AsyncGenerator[httpx.AsyncClient, None]:
29
30
  """
30
31
  Async context manager for manual HTTP client handling.
31
32
  Supports `async with HTTPClientManager.get() as client:`
@@ -33,9 +34,17 @@ class HTTPClientManager:
33
34
  async for client in cls._client_handler():
34
35
  yield client
35
36
 
37
+ @classmethod
38
+ def get_url(cls) -> str:
39
+ if cls.base_url is None:
40
+ raise RuntimeError("Base URL has not been initialized. Call initialize first.")
41
+ return cls.base_url
42
+
36
43
  @classmethod
37
44
  async def dispose(cls) -> None:
38
45
  """Dispose of the HTTP client and release any resources."""
39
46
  if cls.client is not None:
40
47
  await cls.client.aclose()
41
- cls.client = None
48
+ cls.client = None
49
+ if cls.base_url is not None:
50
+ cls.base_url = None
@@ -11,6 +11,7 @@ class BaseTypes:
11
11
  #* Boolean-related types
12
12
  LiteralFalse = Literal[False]
13
13
  LiteralTrue = Literal[True]
14
+ ListOfBools = List[bool]
14
15
 
15
16
  #* Float-related types
16
17
  ListOfFloats = List[float]
@@ -62,8 +62,8 @@ class BaseControllerUtils:
62
62
  Decorator to handle expandable fields validation and processing.
63
63
 
64
64
  Args:
65
- validation_rules: Dictionary where keys are required fields and values are lists of dependent fields
66
- field_expansion_processors: Dictionary of field names to processor functions that handle that field's data
65
+ expandable_fields_dependencies_map: Dictionary where keys are dependency fields and values are lists of dependent fields
66
+ field_expansion_processors: List of processor functions that handle that field's data
67
67
  """
68
68
  def decorator(func:Callable[..., Awaitable[BaseServiceRESTControllerResults]]):
69
69
  @wraps(func)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: maleo_foundation
3
- Version: 0.0.76
3
+ Version: 0.0.78
4
4
  Summary: Foundation package for Maleo
5
5
  Author-email: Agra Bima Yuda <agra@nexmedis.com>
6
6
  License: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "maleo_foundation"
7
- version = "0.0.76"
7
+ version = "0.0.78"
8
8
  description = "Foundation package for Maleo"
9
9
  authors = [
10
10
  { name = "Agra Bima Yuda", email = "agra@nexmedis.com" }