amsdal 0.5.4__cp311-cp311-macosx_10_9_universal2.whl → 0.5.6__cp311-cp311-macosx_10_9_universal2.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.
Files changed (86) hide show
  1. amsdal/__about__.py +1 -1
  2. amsdal/cloud/__init__.cpython-311-darwin.so +0 -0
  3. amsdal/cloud/client.cpython-311-darwin.so +0 -0
  4. amsdal/cloud/constants.cpython-311-darwin.so +0 -0
  5. amsdal/cloud/enums.cpython-311-darwin.so +0 -0
  6. amsdal/cloud/models/__init__.cpython-311-darwin.so +0 -0
  7. amsdal/cloud/models/base.cpython-311-darwin.so +0 -0
  8. amsdal/cloud/services/__init__.cpython-311-darwin.so +0 -0
  9. amsdal/cloud/services/actions/__init__.cpython-311-darwin.so +0 -0
  10. amsdal/cloud/services/actions/add_allowlist_ip.cpython-311-darwin.so +0 -0
  11. amsdal/cloud/services/actions/add_basic_auth.cpython-311-darwin.so +0 -0
  12. amsdal/cloud/services/actions/add_dependency.cpython-311-darwin.so +0 -0
  13. amsdal/cloud/services/actions/add_secret.cpython-311-darwin.so +0 -0
  14. amsdal/cloud/services/actions/base.cpython-311-darwin.so +0 -0
  15. amsdal/cloud/services/actions/create_deploy.cpython-311-darwin.so +0 -0
  16. amsdal/cloud/services/actions/create_env.cpython-311-darwin.so +0 -0
  17. amsdal/cloud/services/actions/create_session.cpython-311-darwin.so +0 -0
  18. amsdal/cloud/services/actions/delete_allowlist_ip.cpython-311-darwin.so +0 -0
  19. amsdal/cloud/services/actions/delete_basic_auth.cpython-311-darwin.so +0 -0
  20. amsdal/cloud/services/actions/delete_dependency.cpython-311-darwin.so +0 -0
  21. amsdal/cloud/services/actions/delete_env.cpython-311-darwin.so +0 -0
  22. amsdal/cloud/services/actions/delete_secret.cpython-311-darwin.so +0 -0
  23. amsdal/cloud/services/actions/destroy_deploy.cpython-311-darwin.so +0 -0
  24. amsdal/cloud/services/actions/expose_db.cpython-311-darwin.so +0 -0
  25. amsdal/cloud/services/actions/get_basic_auth_credentials.cpython-311-darwin.so +0 -0
  26. amsdal/cloud/services/actions/get_monitoring_info.cpython-311-darwin.so +0 -0
  27. amsdal/cloud/services/actions/list_dependencies.cpython-311-darwin.so +0 -0
  28. amsdal/cloud/services/actions/list_deploys.cpython-311-darwin.so +0 -0
  29. amsdal/cloud/services/actions/list_envs.cpython-311-darwin.so +0 -0
  30. amsdal/cloud/services/actions/list_secrets.cpython-311-darwin.so +0 -0
  31. amsdal/cloud/services/actions/manager.cpython-311-darwin.so +0 -0
  32. amsdal/cloud/services/actions/signup_action.cpython-311-darwin.so +0 -0
  33. amsdal/cloud/services/actions/update_deploy.cpython-311-darwin.so +0 -0
  34. amsdal/cloud/services/auth/__init__.cpython-311-darwin.so +0 -0
  35. amsdal/cloud/services/auth/base.cpython-311-darwin.so +0 -0
  36. amsdal/cloud/services/auth/credentials.cpython-311-darwin.so +0 -0
  37. amsdal/cloud/services/auth/manager.cpython-311-darwin.so +0 -0
  38. amsdal/cloud/services/auth/signup_service.cpython-311-darwin.so +0 -0
  39. amsdal/cloud/services/auth/token.cpython-311-darwin.so +0 -0
  40. amsdal/contrib/__init__.cpython-311-darwin.so +0 -0
  41. amsdal/contrib/auth/lifecycle/consumer.pyi +1 -1
  42. amsdal/fixtures/__init__.cpython-311-darwin.so +0 -0
  43. amsdal/fixtures/manager.cpython-311-darwin.so +0 -0
  44. amsdal/fixtures/manager.pyi +1 -1
  45. amsdal/fixtures/utils.cpython-311-darwin.so +0 -0
  46. amsdal/manager.cpython-311-darwin.so +0 -0
  47. amsdal/mixins/__init__.cpython-311-darwin.so +0 -0
  48. amsdal/mixins/class_versions_mixin.cpython-311-darwin.so +0 -0
  49. amsdal/schemas/manager.cpython-311-darwin.so +0 -0
  50. amsdal/services/__init__.cpython-311-darwin.so +0 -0
  51. amsdal/services/transaction_execution.cpython-311-darwin.so +0 -0
  52. amsdal/utils/tests/enums.py +0 -2
  53. amsdal/utils/tests/helpers.py +213 -381
  54. amsdal/utils/tests/migrations.py +179 -0
  55. {amsdal-0.5.4.dist-info → amsdal-0.5.6.dist-info}/METADATA +10 -6
  56. {amsdal-0.5.4.dist-info → amsdal-0.5.6.dist-info}/RECORD +59 -85
  57. {amsdal-0.5.4.dist-info → amsdal-0.5.6.dist-info}/WHEEL +1 -1
  58. amsdal/contrib/auth/models/__init__.pyi +0 -0
  59. amsdal/contrib/auth/models/login_session.pyi +0 -37
  60. amsdal/contrib/auth/models/permission.pyi +0 -18
  61. amsdal/contrib/auth/models/user.pyi +0 -46
  62. amsdal/contrib/frontend_configs/models/__init__.pyi +0 -0
  63. amsdal/contrib/frontend_configs/models/frontend_activator_config.pyi +0 -12
  64. amsdal/contrib/frontend_configs/models/frontend_config_async_validator.pyi +0 -7
  65. amsdal/contrib/frontend_configs/models/frontend_config_control_action.pyi +0 -32
  66. amsdal/contrib/frontend_configs/models/frontend_config_group_validator.pyi +0 -11
  67. amsdal/contrib/frontend_configs/models/frontend_config_option.pyi +0 -8
  68. amsdal/contrib/frontend_configs/models/frontend_config_skip_none_base.pyi +0 -8
  69. amsdal/contrib/frontend_configs/models/frontend_config_slider_option.pyi +0 -9
  70. amsdal/contrib/frontend_configs/models/frontend_config_text_mask.pyi +0 -10
  71. amsdal/contrib/frontend_configs/models/frontend_config_validator.pyi +0 -15
  72. amsdal/contrib/frontend_configs/models/frontend_control_config.pyi +0 -35
  73. amsdal/contrib/frontend_configs/models/frontend_model_config.pyi +0 -9
  74. amsdal/models/__init__.pyi +0 -9
  75. amsdal/models/core/__init__.pyi +0 -0
  76. amsdal/models/core/class_object.pyi +0 -25
  77. amsdal/models/core/class_property.pyi +0 -15
  78. amsdal/models/core/file.pyi +0 -104
  79. amsdal/models/core/fixture.pyi +0 -14
  80. amsdal/models/core/option.pyi +0 -8
  81. amsdal/models/core/storage_metadata.pyi +0 -11
  82. amsdal/models/core/validator.pyi +0 -8
  83. amsdal/models/types/__init__.pyi +0 -0
  84. amsdal/models/types/object.pyi +0 -16
  85. {amsdal-0.5.4.dist-info → amsdal-0.5.6.dist-info}/licenses/LICENSE.txt +0 -0
  86. {amsdal-0.5.4.dist-info → amsdal-0.5.6.dist-info}/top_level.txt +0 -0
@@ -1,32 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_config_skip_none_base import *
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import Any, ClassVar
4
-
5
- class FrontendConfigControlAction(FrontendConfigSkipNoneBase):
6
- __module_type__: ClassVar[ModuleType]
7
- action: str
8
- text: str
9
- type: str
10
- dataLayerEvent: str | None
11
- activator: str | None
12
- icon: str | None
13
- @classmethod
14
- def validate_value_in_options_type(cls, value: Any) -> Any: ...
15
- @classmethod
16
- def validate_action(cls, v: str) -> str:
17
- """
18
- Validates the action string to ensure it is one of the allowed values.
19
-
20
- This method checks if the action string starts with 'navigate::' or is one of the predefined
21
- actions. If the action string is invalid, it raises a ValueError.
22
-
23
- Args:
24
- cls: The class this method is attached to.
25
- v (str): The action string to validate.
26
-
27
- Returns:
28
- str: The validated action string.
29
-
30
- Raises:
31
- ValueError: If the action string is not valid.
32
- """
@@ -1,11 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_config_skip_none_base import *
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import Any, ClassVar
4
-
5
- class FrontendConfigGroupValidator(FrontendConfigSkipNoneBase):
6
- __module_type__: ClassVar[ModuleType]
7
- mainControl: str | None
8
- dependentControls: list[str] | None
9
- condition: str | None
10
- @classmethod
11
- def validate_value_in_options_condition(cls, value: Any) -> Any: ...
@@ -1,8 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_config_skip_none_base import *
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import ClassVar
4
-
5
- class FrontendConfigOption(FrontendConfigSkipNoneBase):
6
- __module_type__: ClassVar[ModuleType]
7
- label: str | None
8
- value: str | None
@@ -1,8 +0,0 @@
1
- from amsdal_models.classes.model import TypeModel
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import Any, ClassVar
4
-
5
- class FrontendConfigSkipNoneBase(TypeModel):
6
- __module_type__: ClassVar[ModuleType]
7
- def model_dump(self, **kwargs: Any) -> dict[str, Any]: ...
8
- def model_dump_json(self, **kwargs: Any) -> str: ...
@@ -1,9 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_config_skip_none_base import *
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import ClassVar
4
-
5
- class FrontendConfigSliderOption(FrontendConfigSkipNoneBase):
6
- __module_type__: ClassVar[ModuleType]
7
- min: float | None
8
- max: float | None
9
- range: bool | None
@@ -1,10 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_config_skip_none_base import *
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import ClassVar
4
-
5
- class FrontendConfigTextMask(FrontendConfigSkipNoneBase):
6
- __module_type__: ClassVar[ModuleType]
7
- mask_string: str
8
- prefix: str | None
9
- suffix: str | None
10
- thousands_separator: str | None
@@ -1,15 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_config_group_validator import *
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import Any, ClassVar
4
-
5
- class FrontendConfigValidator(FrontendConfigGroupValidator):
6
- __module_type__: ClassVar[ModuleType]
7
- mainControl: str | None
8
- dependentControls: list[str] | None
9
- condition: str | None
10
- function: str | None
11
- value: str | None
12
- @classmethod
13
- def validate_value_in_options_condition(cls, value: Any) -> Any: ...
14
- @classmethod
15
- def validate_value_in_options_function(cls, value: Any) -> Any: ...
@@ -1,35 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_activator_config import *
2
- from amsdal.contrib.frontend_configs.models.frontend_config_async_validator import *
3
- from amsdal.contrib.frontend_configs.models.frontend_config_control_action import *
4
- from amsdal.contrib.frontend_configs.models.frontend_config_option import *
5
- from amsdal.contrib.frontend_configs.models.frontend_config_skip_none_base import *
6
- from amsdal.contrib.frontend_configs.models.frontend_config_slider_option import *
7
- from amsdal.contrib.frontend_configs.models.frontend_config_text_mask import *
8
- from amsdal.contrib.frontend_configs.models.frontend_config_validator import *
9
- from amsdal_utils.models.enums import ModuleType
10
- from typing import Any, ClassVar
11
-
12
- class FrontendControlConfig(FrontendConfigSkipNoneBase):
13
- __module_type__: ClassVar[ModuleType]
14
- type: str
15
- name: str
16
- label: str | None
17
- required: bool | None
18
- hideLabel: bool | None
19
- actions: list['FrontendConfigControlAction'] | None
20
- validators: list['FrontendConfigValidator'] | None
21
- asyncValidators: list['FrontendConfigAsyncValidator'] | None
22
- activators: list['FrontendActivatorConfig'] | None
23
- additionalText: str | None
24
- value: Any | None
25
- placeholder: str | None
26
- options: list['FrontendConfigOption'] | None
27
- mask: FrontendConfigTextMask | None
28
- controls: list['FrontendControlConfig'] | None
29
- showSearch: bool | None
30
- sliderOptions: FrontendConfigSliderOption | None
31
- customLabel: list[str] | None
32
- control: FrontendControlConfig | None
33
- entityType: str | None
34
- @classmethod
35
- def validate_value_in_options_type(cls, value: Any) -> Any: ...
@@ -1,9 +0,0 @@
1
- from amsdal.contrib.frontend_configs.models.frontend_control_config import *
2
- from amsdal_models.classes.model import Model
3
- from amsdal_utils.models.enums import ModuleType
4
- from typing import ClassVar
5
-
6
- class FrontendModelConfig(Model):
7
- __module_type__: ClassVar[ModuleType] = ...
8
- class_name: str = ...
9
- control: FrontendControlConfig | None = ...
@@ -1,9 +0,0 @@
1
- from amsdal_models.builder.validators.dict_validators import validate_non_empty_keys as validate_non_empty_keys
2
- from amsdal_models.builder.validators.options_validators import validate_options as validate_options
3
- from amsdal_models.classes.data_models.constraints import UniqueConstraint as UniqueConstraint
4
- from amsdal_models.classes.data_models.indexes import IndexInfo as IndexInfo
5
- from amsdal_models.classes.model import Model as Model, TypeModel as TypeModel
6
- from amsdal_models.classes.relationships.many_reference_field import ManyReferenceField as ManyReferenceField
7
- from amsdal_models.classes.relationships.reference_field import ReferenceField as ReferenceField
8
-
9
- __all__ = ['IndexInfo', 'ManyReferenceField', 'Model', 'ReferenceField', 'TypeModel', 'UniqueConstraint', 'validate_non_empty_keys', 'validate_options']
File without changes
@@ -1,25 +0,0 @@
1
- from amsdal.models.core.class_property import *
2
- from amsdal.models.core.storage_metadata import *
3
- from amsdal_models.classes.model import Model
4
- from amsdal_utils.models.enums import ModuleType
5
- from typing import Any, ClassVar
6
-
7
- class ClassObject(Model):
8
- __module_type__: ClassVar[ModuleType] = ...
9
- title: str = ...
10
- type: str = ...
11
- module_type: str = ...
12
- properties: dict[str, ClassProperty | None] | None = ...
13
- required: list[str] | None = ...
14
- custom_code: str | None = ...
15
- storage_metadata: StorageMetadata | None = ...
16
- @classmethod
17
- def _non_empty_keys_properties(cls, value: Any) -> Any: ...
18
- @property
19
- def display_name(self) -> str:
20
- """
21
- Returns the display name of the object.
22
-
23
- Returns:
24
- str: The display name, which is the title of the object.
25
- """
@@ -1,15 +0,0 @@
1
- from amsdal.models.core.option import *
2
- from amsdal_models.classes.model import TypeModel
3
- from amsdal_utils.models.enums import ModuleType
4
- from typing import Any, ClassVar
5
-
6
- class ClassProperty(TypeModel):
7
- __module_type__: ClassVar[ModuleType]
8
- title: str | None
9
- type: str
10
- default: Any | None
11
- options: list['Option'] | None
12
- items: dict[str, Any | None] | None
13
- discriminator: str | None
14
- @classmethod
15
- def _non_empty_keys_items(cls, value: Any) -> Any: ...
@@ -1,104 +0,0 @@
1
- from amsdal_models.classes.model import Model
2
- from amsdal_utils.models.enums import ModuleType
3
- from pathlib import Path
4
- from typing import BinaryIO, ClassVar
5
-
6
- class File(Model):
7
- __module_type__: ClassVar[ModuleType] = ...
8
- filename: str = ...
9
- data: bytes = ...
10
- size: float | None = ...
11
- def __repr__(self) -> str: ...
12
- def __str__(self) -> str: ...
13
- async def apre_create(self) -> None:
14
- """
15
- Prepares the object for creation by setting its size attribute.
16
-
17
- This method calculates the size of the object's data and assigns it to the size attribute.
18
- If the data is None, it defaults to an empty byte string.
19
-
20
- Args:
21
- None
22
- """
23
- async def apre_update(self) -> None:
24
- """
25
- Prepares the object for update by setting its size attribute.
26
-
27
- This method calculates the size of the object's data and assigns it to the size attribute.
28
- If the data is None, it defaults to an empty byte string.
29
-
30
- Args:
31
- None
32
- """
33
- @classmethod
34
- def data_base64_decode(cls, v: bytes) -> bytes:
35
- """
36
- Decodes a base64-encoded byte string if it is base64-encoded.
37
-
38
- This method checks if the provided byte string is base64-encoded and decodes it if true.
39
- If the byte string is not base64-encoded, it returns the original byte string.
40
-
41
- Args:
42
- cls: The class this method belongs to.
43
- v (bytes): The byte string to be checked and potentially decoded.
44
-
45
- Returns:
46
- bytes: The decoded byte string if it was base64-encoded, otherwise the original byte string.
47
- """
48
- @classmethod
49
- def from_file(cls, file_or_path: Path | BinaryIO) -> File:
50
- """
51
- Creates a `File` object from a file path or a binary file object.
52
-
53
- Args:
54
- file_or_path (Path | BinaryIO): The file path or binary file object.
55
-
56
- Returns:
57
- File: The created `File` object.
58
-
59
- Raises:
60
- ValueError: If the provided path is a directory.
61
- """
62
- @property
63
- def mimetype(self) -> str | None:
64
- """
65
- Returns the MIME type of the file based on its filename.
66
-
67
- This method uses the `mimetypes` module to guess the MIME type of the file.
68
-
69
- Returns:
70
- str | None: The guessed MIME type of the file, or None if it cannot be determined.
71
- """
72
- def pre_create(self) -> None:
73
- """
74
- Prepares the object for creation by setting its size attribute.
75
-
76
- This method calculates the size of the object's data and assigns it to the size attribute.
77
- If the data is None, it defaults to an empty byte string.
78
-
79
- Args:
80
- None
81
- """
82
- def pre_update(self) -> None:
83
- """
84
- Prepares the object for update by setting its size attribute.
85
-
86
- This method calculates the size of the object's data and assigns it to the size attribute.
87
- If the data is None, it defaults to an empty byte string.
88
-
89
- Args:
90
- None
91
- """
92
- def to_file(self, file_or_path: Path | BinaryIO) -> None:
93
- """
94
- Writes the object's data to a file path or a binary file object.
95
-
96
- Args:
97
- file_or_path (Path | BinaryIO): The file path or binary file object where the data will be written.
98
-
99
- Returns:
100
- None
101
-
102
- Raises:
103
- ValueError: If the provided path is a directory.
104
- """
@@ -1,14 +0,0 @@
1
- from amsdal_models.classes.data_models.constraints import UniqueConstraint
2
- from amsdal_models.classes.model import Model
3
- from amsdal_utils.models.enums import ModuleType
4
- from typing import Any, ClassVar
5
-
6
- class Fixture(Model):
7
- __module_type__: ClassVar[ModuleType] = ...
8
- __constraints__: ClassVar[list[UniqueConstraint]] = ...
9
- class_name: str | None = ...
10
- order: float | None = ...
11
- external_id: str = ...
12
- data: dict[str, Any | None] = ...
13
- @classmethod
14
- def _non_empty_keys_data(cls, value: Any) -> Any: ...
@@ -1,8 +0,0 @@
1
- from amsdal_models.classes.model import TypeModel
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import ClassVar
4
-
5
- class Option(TypeModel):
6
- __module_type__: ClassVar[ModuleType]
7
- key: str
8
- value: str
@@ -1,11 +0,0 @@
1
- from amsdal_models.classes.model import TypeModel
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import ClassVar
4
-
5
- class StorageMetadata(TypeModel):
6
- __module_type__: ClassVar[ModuleType]
7
- table_name: str | None
8
- db_fields: dict[str, list[str]] | None
9
- primary_key: list[str] | None
10
- indexed: list[list[str]] | None
11
- unique: list[list[str]] | None
@@ -1,8 +0,0 @@
1
- from amsdal_models.classes.model import TypeModel
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import Any, ClassVar
4
-
5
- class Validator(TypeModel):
6
- __module_type__: ClassVar[ModuleType]
7
- name: str
8
- data: Any
File without changes
@@ -1,16 +0,0 @@
1
- from amsdal_models.classes.model import Model
2
- from amsdal_utils.models.enums import ModuleType
3
- from typing import Any, ClassVar
4
-
5
- class Object(Model):
6
- __module_type__: ClassVar[ModuleType] = ...
7
- title: str = ...
8
- type: str = ...
9
- module_type: str = ...
10
- default: Any | None = ...
11
- properties: dict[str, Any | None] | None = ...
12
- required: list[str] | None = ...
13
- custom_code: str | None = ...
14
- meta_class: str | None = ...
15
- @classmethod
16
- def _non_empty_keys_properties(cls, value: Any) -> Any: ...