development-framework-cli 1.7.3__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.
Files changed (71) hide show
  1. development_framework_cli-1.7.3.dist-info/METADATA +141 -0
  2. development_framework_cli-1.7.3.dist-info/RECORD +71 -0
  3. development_framework_cli-1.7.3.dist-info/WHEEL +4 -0
  4. development_framework_cli-1.7.3.dist-info/entry_points.txt +2 -0
  5. development_framework_cli-1.7.3.dist-info/licenses/LICENSE +21 -0
  6. dm_cli/__init__.py +1 -0
  7. dm_cli/cli.py +180 -0
  8. dm_cli/command_group/__init__.py +0 -0
  9. dm_cli/command_group/data_source.py +176 -0
  10. dm_cli/command_group/entities.py +116 -0
  11. dm_cli/dmss.py +104 -0
  12. dm_cli/dmss_api/__init__.py +27 -0
  13. dm_cli/dmss_api/api/__init__.py +3 -0
  14. dm_cli/dmss_api/api/access_control_api.py +349 -0
  15. dm_cli/dmss_api/api/attribute_api.py +175 -0
  16. dm_cli/dmss_api/api/blob_api.py +344 -0
  17. dm_cli/dmss_api/api/blueprint_api.py +326 -0
  18. dm_cli/dmss_api/api/datasource_api.py +448 -0
  19. dm_cli/dmss_api/api/default_api.py +4439 -0
  20. dm_cli/dmss_api/api/document_api.py +922 -0
  21. dm_cli/dmss_api/api/entity_api.py +464 -0
  22. dm_cli/dmss_api/api/export_api.py +313 -0
  23. dm_cli/dmss_api/api/file_api.py +197 -0
  24. dm_cli/dmss_api/api/health_check_api.py +160 -0
  25. dm_cli/dmss_api/api/lookup_table_api.py +323 -0
  26. dm_cli/dmss_api/api/meta_api.py +185 -0
  27. dm_cli/dmss_api/api/personal_access_token_api.py +433 -0
  28. dm_cli/dmss_api/api/reference_api.py +174 -0
  29. dm_cli/dmss_api/api/search_api.py +183 -0
  30. dm_cli/dmss_api/api/whoami_api.py +163 -0
  31. dm_cli/dmss_api/api_client.py +896 -0
  32. dm_cli/dmss_api/apis/__init__.py +32 -0
  33. dm_cli/dmss_api/configuration.py +482 -0
  34. dm_cli/dmss_api/exceptions.py +158 -0
  35. dm_cli/dmss_api/model/__init__.py +5 -0
  36. dm_cli/dmss_api/model/access_control_list.py +287 -0
  37. dm_cli/dmss_api/model/access_level.py +290 -0
  38. dm_cli/dmss_api/model/acl.py +287 -0
  39. dm_cli/dmss_api/model/data_source_information.py +282 -0
  40. dm_cli/dmss_api/model/data_source_request.py +281 -0
  41. dm_cli/dmss_api/model/dependency.py +294 -0
  42. dm_cli/dmss_api/model/entity.py +275 -0
  43. dm_cli/dmss_api/model/error_response.py +278 -0
  44. dm_cli/dmss_api/model/export_meta_response.py +277 -0
  45. dm_cli/dmss_api/model/get_blueprint_response.py +280 -0
  46. dm_cli/dmss_api/model/lookup.py +283 -0
  47. dm_cli/dmss_api/model/pat_data.py +299 -0
  48. dm_cli/dmss_api/model/recipe.py +311 -0
  49. dm_cli/dmss_api/model/recipe_attribute.py +304 -0
  50. dm_cli/dmss_api/model/reference.py +280 -0
  51. dm_cli/dmss_api/model/reference_entity.py +288 -0
  52. dm_cli/dmss_api/model/repository.py +317 -0
  53. dm_cli/dmss_api/model/repository_type.py +290 -0
  54. dm_cli/dmss_api/model/storage_attribute.py +295 -0
  55. dm_cli/dmss_api/model/storage_data_types.py +292 -0
  56. dm_cli/dmss_api/model/storage_recipe.py +293 -0
  57. dm_cli/dmss_api/model_utils.py +2057 -0
  58. dm_cli/dmss_api/models/__init__.py +29 -0
  59. dm_cli/dmss_api/rest.py +358 -0
  60. dm_cli/domain.py +166 -0
  61. dm_cli/enums.py +48 -0
  62. dm_cli/import_entity.py +128 -0
  63. dm_cli/import_package.py +173 -0
  64. dm_cli/package_tree_from_zip.py +120 -0
  65. dm_cli/state.py +12 -0
  66. dm_cli/utils/__init__.py +0 -0
  67. dm_cli/utils/file_structure.py +31 -0
  68. dm_cli/utils/reference.py +129 -0
  69. dm_cli/utils/resolve_local_ids.py +142 -0
  70. dm_cli/utils/utils.py +161 -0
  71. dm_cli/utils/zip.py +70 -0
@@ -0,0 +1,277 @@
1
+ """
2
+ Data Modelling Storage Service
3
+
4
+ API for basic data modelling interaction # noqa: E501
5
+
6
+ The version of the OpenAPI document: 1.3.0
7
+ Generated by: https://openapi-generator.tech
8
+ """
9
+
10
+
11
+ import re # noqa: F401
12
+ import sys # noqa: F401
13
+
14
+ from dm_cli.dmss_api.exceptions import ApiAttributeError
15
+ from dm_cli.dmss_api.model_utils import ( # noqa: F401
16
+ ApiTypeError,
17
+ ModelComposed,
18
+ ModelNormal,
19
+ ModelSimple,
20
+ OpenApiModel,
21
+ cached_property,
22
+ change_keys_js_to_python,
23
+ convert_js_args_to_python_args,
24
+ date,
25
+ datetime,
26
+ file_type,
27
+ none_type,
28
+ validate_get_composed_info,
29
+ )
30
+
31
+
32
+ def lazy_import():
33
+ from dm_cli.dmss_api.model.dependency import Dependency
34
+ globals()['Dependency'] = Dependency
35
+
36
+
37
+ class ExportMetaResponse(ModelNormal):
38
+ """NOTE: This class is auto generated by OpenAPI Generator.
39
+ Ref: https://openapi-generator.tech
40
+
41
+ Do not edit the class manually.
42
+
43
+ Attributes:
44
+ allowed_values (dict): The key is the tuple path to the attribute
45
+ and the for var_name this is (var_name,). The value is a dict
46
+ with a capitalized key describing the allowed value and an allowed
47
+ value. These dicts store the allowed enum values.
48
+ attribute_map (dict): The key is attribute name
49
+ and the value is json key in definition.
50
+ discriminator_value_class_map (dict): A dict to go from the discriminator
51
+ variable value to the discriminator class name.
52
+ validations (dict): The key is the tuple path to the attribute
53
+ and the for var_name this is (var_name,). The value is a dict
54
+ that stores validations for max_length, min_length, max_items,
55
+ min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum,
56
+ inclusive_minimum, and regex.
57
+ additional_properties_type (tuple): A tuple of classes accepted
58
+ as additional properties values.
59
+ """
60
+
61
+ allowed_values = {
62
+ }
63
+
64
+ validations = {
65
+ }
66
+
67
+ @cached_property
68
+ def additional_properties_type():
69
+ """
70
+ This must be a method because a model may have properties that are
71
+ of type self, this must run after the class is loaded
72
+ """
73
+ lazy_import()
74
+ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501
75
+
76
+ _nullable = False
77
+
78
+ @cached_property
79
+ def openapi_types():
80
+ """
81
+ This must be a method because a model may have properties that are
82
+ of type self, this must run after the class is loaded
83
+
84
+ Returns
85
+ openapi_types (dict): The key is attribute name
86
+ and the value is attribute type.
87
+ """
88
+ lazy_import()
89
+ return {
90
+ 'type': (str,), # noqa: E501
91
+ 'version': (str,), # noqa: E501
92
+ 'dependencies': ([Dependency],), # noqa: E501
93
+ }
94
+
95
+ @cached_property
96
+ def discriminator():
97
+ return None
98
+
99
+
100
+ attribute_map = {
101
+ 'type': 'type', # noqa: E501
102
+ 'version': 'version', # noqa: E501
103
+ 'dependencies': 'dependencies', # noqa: E501
104
+ }
105
+
106
+ read_only_vars = {
107
+ }
108
+
109
+ _composed_schemas = {}
110
+
111
+ @classmethod
112
+ @convert_js_args_to_python_args
113
+ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501
114
+ """ExportMetaResponse - a model defined in OpenAPI
115
+
116
+ Keyword Args:
117
+ _check_type (bool): if True, values for parameters in openapi_types
118
+ will be type checked and a TypeError will be
119
+ raised if the wrong type is input.
120
+ Defaults to True
121
+ _path_to_item (tuple/list): This is a list of keys or values to
122
+ drill down to the model in received_data
123
+ when deserializing a response
124
+ _spec_property_naming (bool): True if the variable names in the input data
125
+ are serialized names, as specified in the OpenAPI document.
126
+ False if the variable names in the input data
127
+ are pythonic names, e.g. snake case (default)
128
+ _configuration (Configuration): the instance to use when
129
+ deserializing a file_type parameter.
130
+ If passed, type conversion is attempted
131
+ If omitted no type conversion is done.
132
+ _visited_composed_classes (tuple): This stores a tuple of
133
+ classes that we have traveled through so that
134
+ if we see that class again we will not use its
135
+ discriminator again.
136
+ When traveling through a discriminator, the
137
+ composed schema that is
138
+ is traveled through is added to this set.
139
+ For example if Animal has a discriminator
140
+ petType and we pass in "Dog", and the class Dog
141
+ allOf includes Animal, we move through Animal
142
+ once using the discriminator, and pick Dog.
143
+ Then in Dog, we will make an instance of the
144
+ Animal class but this time we won't travel
145
+ through its discriminator because we passed in
146
+ _visited_composed_classes = (Animal,)
147
+ type (str): [optional] if omitted the server will use the default value of "CORE:Meta" # noqa: E501
148
+ version (str): [optional] if omitted the server will use the default value of "0.0.0" # noqa: E501
149
+ dependencies ([Dependency]): [optional] if omitted the server will use the default value of [] # noqa: E501
150
+ """
151
+
152
+ _check_type = kwargs.pop('_check_type', True)
153
+ _spec_property_naming = kwargs.pop('_spec_property_naming', True)
154
+ _path_to_item = kwargs.pop('_path_to_item', ())
155
+ _configuration = kwargs.pop('_configuration', None)
156
+ _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
157
+
158
+ self = super(OpenApiModel, cls).__new__(cls)
159
+
160
+ if args:
161
+ for arg in args:
162
+ if isinstance(arg, dict):
163
+ kwargs.update(arg)
164
+ else:
165
+ raise ApiTypeError(
166
+ "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
167
+ args,
168
+ self.__class__.__name__,
169
+ ),
170
+ path_to_item=_path_to_item,
171
+ valid_classes=(self.__class__,),
172
+ )
173
+
174
+ self._data_store = {}
175
+ self._check_type = _check_type
176
+ self._spec_property_naming = _spec_property_naming
177
+ self._path_to_item = _path_to_item
178
+ self._configuration = _configuration
179
+ self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
180
+
181
+ for var_name, var_value in kwargs.items():
182
+ if var_name not in self.attribute_map and \
183
+ self._configuration is not None and \
184
+ self._configuration.discard_unknown_keys and \
185
+ self.additional_properties_type is None:
186
+ # discard variable.
187
+ continue
188
+ setattr(self, var_name, var_value)
189
+ return self
190
+
191
+ required_properties = set([
192
+ '_data_store',
193
+ '_check_type',
194
+ '_spec_property_naming',
195
+ '_path_to_item',
196
+ '_configuration',
197
+ '_visited_composed_classes',
198
+ ])
199
+
200
+ @convert_js_args_to_python_args
201
+ def __init__(self, *args, **kwargs): # noqa: E501
202
+ """ExportMetaResponse - a model defined in OpenAPI
203
+
204
+ Keyword Args:
205
+ _check_type (bool): if True, values for parameters in openapi_types
206
+ will be type checked and a TypeError will be
207
+ raised if the wrong type is input.
208
+ Defaults to True
209
+ _path_to_item (tuple/list): This is a list of keys or values to
210
+ drill down to the model in received_data
211
+ when deserializing a response
212
+ _spec_property_naming (bool): True if the variable names in the input data
213
+ are serialized names, as specified in the OpenAPI document.
214
+ False if the variable names in the input data
215
+ are pythonic names, e.g. snake case (default)
216
+ _configuration (Configuration): the instance to use when
217
+ deserializing a file_type parameter.
218
+ If passed, type conversion is attempted
219
+ If omitted no type conversion is done.
220
+ _visited_composed_classes (tuple): This stores a tuple of
221
+ classes that we have traveled through so that
222
+ if we see that class again we will not use its
223
+ discriminator again.
224
+ When traveling through a discriminator, the
225
+ composed schema that is
226
+ is traveled through is added to this set.
227
+ For example if Animal has a discriminator
228
+ petType and we pass in "Dog", and the class Dog
229
+ allOf includes Animal, we move through Animal
230
+ once using the discriminator, and pick Dog.
231
+ Then in Dog, we will make an instance of the
232
+ Animal class but this time we won't travel
233
+ through its discriminator because we passed in
234
+ _visited_composed_classes = (Animal,)
235
+ type (str): [optional] if omitted the server will use the default value of "CORE:Meta" # noqa: E501
236
+ version (str): [optional] if omitted the server will use the default value of "0.0.0" # noqa: E501
237
+ dependencies ([Dependency]): [optional] if omitted the server will use the default value of [] # noqa: E501
238
+ """
239
+
240
+ _check_type = kwargs.pop('_check_type', True)
241
+ _spec_property_naming = kwargs.pop('_spec_property_naming', False)
242
+ _path_to_item = kwargs.pop('_path_to_item', ())
243
+ _configuration = kwargs.pop('_configuration', None)
244
+ _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
245
+
246
+ if args:
247
+ for arg in args:
248
+ if isinstance(arg, dict):
249
+ kwargs.update(arg)
250
+ else:
251
+ raise ApiTypeError(
252
+ "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
253
+ args,
254
+ self.__class__.__name__,
255
+ ),
256
+ path_to_item=_path_to_item,
257
+ valid_classes=(self.__class__,),
258
+ )
259
+
260
+ self._data_store = {}
261
+ self._check_type = _check_type
262
+ self._spec_property_naming = _spec_property_naming
263
+ self._path_to_item = _path_to_item
264
+ self._configuration = _configuration
265
+ self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
266
+
267
+ for var_name, var_value in kwargs.items():
268
+ if var_name not in self.attribute_map and \
269
+ self._configuration is not None and \
270
+ self._configuration.discard_unknown_keys and \
271
+ self.additional_properties_type is None:
272
+ # discard variable.
273
+ continue
274
+ setattr(self, var_name, var_value)
275
+ if var_name in self.read_only_vars:
276
+ raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
277
+ f"class with read only attributes.")
@@ -0,0 +1,280 @@
1
+ """
2
+ Data Modelling Storage Service
3
+
4
+ API for basic data modelling interaction # noqa: E501
5
+
6
+ The version of the OpenAPI document: 1.3.0
7
+ Generated by: https://openapi-generator.tech
8
+ """
9
+
10
+
11
+ import re # noqa: F401
12
+ import sys # noqa: F401
13
+
14
+ from dm_cli.dmss_api.exceptions import ApiAttributeError
15
+ from dm_cli.dmss_api.model_utils import ( # noqa: F401
16
+ ApiTypeError,
17
+ ModelComposed,
18
+ ModelNormal,
19
+ ModelSimple,
20
+ OpenApiModel,
21
+ cached_property,
22
+ change_keys_js_to_python,
23
+ convert_js_args_to_python_args,
24
+ date,
25
+ datetime,
26
+ file_type,
27
+ none_type,
28
+ validate_get_composed_info,
29
+ )
30
+
31
+
32
+ class GetBlueprintResponse(ModelNormal):
33
+ """NOTE: This class is auto generated by OpenAPI Generator.
34
+ Ref: https://openapi-generator.tech
35
+
36
+ Do not edit the class manually.
37
+
38
+ Attributes:
39
+ allowed_values (dict): The key is the tuple path to the attribute
40
+ and the for var_name this is (var_name,). The value is a dict
41
+ with a capitalized key describing the allowed value and an allowed
42
+ value. These dicts store the allowed enum values.
43
+ attribute_map (dict): The key is attribute name
44
+ and the value is json key in definition.
45
+ discriminator_value_class_map (dict): A dict to go from the discriminator
46
+ variable value to the discriminator class name.
47
+ validations (dict): The key is the tuple path to the attribute
48
+ and the for var_name this is (var_name,). The value is a dict
49
+ that stores validations for max_length, min_length, max_items,
50
+ min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum,
51
+ inclusive_minimum, and regex.
52
+ additional_properties_type (tuple): A tuple of classes accepted
53
+ as additional properties values.
54
+ """
55
+
56
+ allowed_values = {
57
+ }
58
+
59
+ validations = {
60
+ }
61
+
62
+ @cached_property
63
+ def additional_properties_type():
64
+ """
65
+ This must be a method because a model may have properties that are
66
+ of type self, this must run after the class is loaded
67
+ """
68
+ return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501
69
+
70
+ _nullable = False
71
+
72
+ @cached_property
73
+ def openapi_types():
74
+ """
75
+ This must be a method because a model may have properties that are
76
+ of type self, this must run after the class is loaded
77
+
78
+ Returns
79
+ openapi_types (dict): The key is attribute name
80
+ and the value is attribute type.
81
+ """
82
+ return {
83
+ 'blueprint': ({str: (bool, date, datetime, dict, float, int, list, str, none_type)},), # noqa: E501
84
+ 'ui_recipes': ([{str: (bool, date, datetime, dict, float, int, list, str, none_type)}],), # noqa: E501
85
+ 'storage_recipes': ([{str: (bool, date, datetime, dict, float, int, list, str, none_type)}],), # noqa: E501
86
+ }
87
+
88
+ @cached_property
89
+ def discriminator():
90
+ return None
91
+
92
+
93
+ attribute_map = {
94
+ 'blueprint': 'blueprint', # noqa: E501
95
+ 'ui_recipes': 'uiRecipes', # noqa: E501
96
+ 'storage_recipes': 'storageRecipes', # noqa: E501
97
+ }
98
+
99
+ read_only_vars = {
100
+ }
101
+
102
+ _composed_schemas = {}
103
+
104
+ @classmethod
105
+ @convert_js_args_to_python_args
106
+ def _from_openapi_data(cls, blueprint, ui_recipes, storage_recipes, *args, **kwargs): # noqa: E501
107
+ """GetBlueprintResponse - a model defined in OpenAPI
108
+
109
+ Args:
110
+ blueprint ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}):
111
+ ui_recipes ([{str: (bool, date, datetime, dict, float, int, list, str, none_type)}]):
112
+ storage_recipes ([{str: (bool, date, datetime, dict, float, int, list, str, none_type)}]):
113
+
114
+ Keyword Args:
115
+ _check_type (bool): if True, values for parameters in openapi_types
116
+ will be type checked and a TypeError will be
117
+ raised if the wrong type is input.
118
+ Defaults to True
119
+ _path_to_item (tuple/list): This is a list of keys or values to
120
+ drill down to the model in received_data
121
+ when deserializing a response
122
+ _spec_property_naming (bool): True if the variable names in the input data
123
+ are serialized names, as specified in the OpenAPI document.
124
+ False if the variable names in the input data
125
+ are pythonic names, e.g. snake case (default)
126
+ _configuration (Configuration): the instance to use when
127
+ deserializing a file_type parameter.
128
+ If passed, type conversion is attempted
129
+ If omitted no type conversion is done.
130
+ _visited_composed_classes (tuple): This stores a tuple of
131
+ classes that we have traveled through so that
132
+ if we see that class again we will not use its
133
+ discriminator again.
134
+ When traveling through a discriminator, the
135
+ composed schema that is
136
+ is traveled through is added to this set.
137
+ For example if Animal has a discriminator
138
+ petType and we pass in "Dog", and the class Dog
139
+ allOf includes Animal, we move through Animal
140
+ once using the discriminator, and pick Dog.
141
+ Then in Dog, we will make an instance of the
142
+ Animal class but this time we won't travel
143
+ through its discriminator because we passed in
144
+ _visited_composed_classes = (Animal,)
145
+ """
146
+
147
+ _check_type = kwargs.pop('_check_type', True)
148
+ _spec_property_naming = kwargs.pop('_spec_property_naming', True)
149
+ _path_to_item = kwargs.pop('_path_to_item', ())
150
+ _configuration = kwargs.pop('_configuration', None)
151
+ _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
152
+
153
+ self = super(OpenApiModel, cls).__new__(cls)
154
+
155
+ if args:
156
+ for arg in args:
157
+ if isinstance(arg, dict):
158
+ kwargs.update(arg)
159
+ else:
160
+ raise ApiTypeError(
161
+ "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
162
+ args,
163
+ self.__class__.__name__,
164
+ ),
165
+ path_to_item=_path_to_item,
166
+ valid_classes=(self.__class__,),
167
+ )
168
+
169
+ self._data_store = {}
170
+ self._check_type = _check_type
171
+ self._spec_property_naming = _spec_property_naming
172
+ self._path_to_item = _path_to_item
173
+ self._configuration = _configuration
174
+ self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
175
+
176
+ self.blueprint = blueprint
177
+ self.ui_recipes = ui_recipes
178
+ self.storage_recipes = storage_recipes
179
+ for var_name, var_value in kwargs.items():
180
+ if var_name not in self.attribute_map and \
181
+ self._configuration is not None and \
182
+ self._configuration.discard_unknown_keys and \
183
+ self.additional_properties_type is None:
184
+ # discard variable.
185
+ continue
186
+ setattr(self, var_name, var_value)
187
+ return self
188
+
189
+ required_properties = set([
190
+ '_data_store',
191
+ '_check_type',
192
+ '_spec_property_naming',
193
+ '_path_to_item',
194
+ '_configuration',
195
+ '_visited_composed_classes',
196
+ ])
197
+
198
+ @convert_js_args_to_python_args
199
+ def __init__(self, blueprint, ui_recipes, storage_recipes, *args, **kwargs): # noqa: E501
200
+ """GetBlueprintResponse - a model defined in OpenAPI
201
+
202
+ Args:
203
+ blueprint ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}):
204
+ ui_recipes ([{str: (bool, date, datetime, dict, float, int, list, str, none_type)}]):
205
+ storage_recipes ([{str: (bool, date, datetime, dict, float, int, list, str, none_type)}]):
206
+
207
+ Keyword Args:
208
+ _check_type (bool): if True, values for parameters in openapi_types
209
+ will be type checked and a TypeError will be
210
+ raised if the wrong type is input.
211
+ Defaults to True
212
+ _path_to_item (tuple/list): This is a list of keys or values to
213
+ drill down to the model in received_data
214
+ when deserializing a response
215
+ _spec_property_naming (bool): True if the variable names in the input data
216
+ are serialized names, as specified in the OpenAPI document.
217
+ False if the variable names in the input data
218
+ are pythonic names, e.g. snake case (default)
219
+ _configuration (Configuration): the instance to use when
220
+ deserializing a file_type parameter.
221
+ If passed, type conversion is attempted
222
+ If omitted no type conversion is done.
223
+ _visited_composed_classes (tuple): This stores a tuple of
224
+ classes that we have traveled through so that
225
+ if we see that class again we will not use its
226
+ discriminator again.
227
+ When traveling through a discriminator, the
228
+ composed schema that is
229
+ is traveled through is added to this set.
230
+ For example if Animal has a discriminator
231
+ petType and we pass in "Dog", and the class Dog
232
+ allOf includes Animal, we move through Animal
233
+ once using the discriminator, and pick Dog.
234
+ Then in Dog, we will make an instance of the
235
+ Animal class but this time we won't travel
236
+ through its discriminator because we passed in
237
+ _visited_composed_classes = (Animal,)
238
+ """
239
+
240
+ _check_type = kwargs.pop('_check_type', True)
241
+ _spec_property_naming = kwargs.pop('_spec_property_naming', False)
242
+ _path_to_item = kwargs.pop('_path_to_item', ())
243
+ _configuration = kwargs.pop('_configuration', None)
244
+ _visited_composed_classes = kwargs.pop('_visited_composed_classes', ())
245
+
246
+ if args:
247
+ for arg in args:
248
+ if isinstance(arg, dict):
249
+ kwargs.update(arg)
250
+ else:
251
+ raise ApiTypeError(
252
+ "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % (
253
+ args,
254
+ self.__class__.__name__,
255
+ ),
256
+ path_to_item=_path_to_item,
257
+ valid_classes=(self.__class__,),
258
+ )
259
+
260
+ self._data_store = {}
261
+ self._check_type = _check_type
262
+ self._spec_property_naming = _spec_property_naming
263
+ self._path_to_item = _path_to_item
264
+ self._configuration = _configuration
265
+ self._visited_composed_classes = _visited_composed_classes + (self.__class__,)
266
+
267
+ self.blueprint = blueprint
268
+ self.ui_recipes = ui_recipes
269
+ self.storage_recipes = storage_recipes
270
+ for var_name, var_value in kwargs.items():
271
+ if var_name not in self.attribute_map and \
272
+ self._configuration is not None and \
273
+ self._configuration.discard_unknown_keys and \
274
+ self.additional_properties_type is None:
275
+ # discard variable.
276
+ continue
277
+ setattr(self, var_name, var_value)
278
+ if var_name in self.read_only_vars:
279
+ raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate "
280
+ f"class with read only attributes.")