Skip to content
This repository was archived by the owner on Dec 25, 2024. It is now read-only.

Commit f183080

Browse files
committed
Removes schema_input template files
1 parent f5ccbe3 commit f183080

37 files changed

Lines changed: 217 additions & 520 deletions

File tree

modules/openapi-json-schema-generator/src/main/resources/python/paths/path/verb/_helper_operation_args_body_nonref.hbs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,4 @@ body: typing.Union[
1919
{{#unless required}}
2020
schemas.Unset,
2121
{{/unless}}
22-
{{#each getContentSchemas}}
23-
{{> _helper_schema_python_types_newline }}
24-
{{/each}}
25-
]{{#unless required}} = schemas.unset{{/unless}},
22+
]{{#unless required}} = schemas.unset{{/unless}},

samples/openapi3/client/petstore/python/src/petstore_api/paths/another_fake_dummy/patch/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,8 @@ def _call_123_test__special_tags(
3434
self,
3535
body: typing.Union[
3636
request_body.request_body_client.content.application_json.schema.client.ClientDict,
37-
dict,
38-
immutabledict.immutabledict
39-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
37+
],
38+
content_type: typing_extensions.Literal["application/json"] = "application/json",
4039
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
4140
server_index: typing.Optional[int] = None,
4241
stream: bool = False,
@@ -49,9 +48,8 @@ def _call_123_test__special_tags(
4948
self,
5049
body: typing.Union[
5150
request_body.request_body_client.content.application_json.schema.client.ClientDict,
52-
dict,
53-
immutabledict.immutabledict
54-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
51+
],
52+
content_type: typing_extensions.Literal["application/json"] = "application/json",
5553
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
5654
server_index: typing.Optional[int] = None,
5755
stream: bool = False,
@@ -63,9 +61,8 @@ def _call_123_test__special_tags(
6361
self,
6462
body: typing.Union[
6563
request_body.request_body_client.content.application_json.schema.client.ClientDict,
66-
dict,
67-
immutabledict.immutabledict
68-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
64+
],
65+
content_type: typing_extensions.Literal["application/json"] = "application/json",
6966
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
7067
server_index: typing.Optional[int] = None,
7168
stream: bool = False,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake/get/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,8 @@ def _enum_parameters(
102102
body: typing.Union[
103103
request_body.content.application_x_www_form_urlencoded.schema.SchemaDict,
104104
schemas.Unset,
105-
dict,
106-
immutabledict.immutabledict
107-
] = schemas.unset, query_params: typing.Optional[RequestQueryParameters.Params] = None,
105+
] = schemas.unset,
106+
query_params: typing.Optional[RequestQueryParameters.Params] = None,
108107
header_params: typing.Optional[RequestHeaderParameters.Params] = None,
109108
content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
110109
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
@@ -120,9 +119,8 @@ def _enum_parameters(
120119
body: typing.Union[
121120
request_body.content.application_x_www_form_urlencoded.schema.SchemaDict,
122121
schemas.Unset,
123-
dict,
124-
immutabledict.immutabledict
125-
] = schemas.unset, query_params: typing.Optional[RequestQueryParameters.Params] = None,
122+
] = schemas.unset,
123+
query_params: typing.Optional[RequestQueryParameters.Params] = None,
126124
header_params: typing.Optional[RequestHeaderParameters.Params] = None,
127125
content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
128126
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
@@ -137,9 +135,8 @@ def _enum_parameters(
137135
body: typing.Union[
138136
request_body.content.application_x_www_form_urlencoded.schema.SchemaDict,
139137
schemas.Unset,
140-
dict,
141-
immutabledict.immutabledict
142-
] = schemas.unset, query_params: typing.Optional[RequestQueryParameters.Params] = None,
138+
] = schemas.unset,
139+
query_params: typing.Optional[RequestQueryParameters.Params] = None,
143140
header_params: typing.Optional[RequestHeaderParameters.Params] = None,
144141
content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
145142
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake/patch/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,8 @@ def _client_model(
3434
self,
3535
body: typing.Union[
3636
request_body.request_body_client.content.application_json.schema.client.ClientDict,
37-
dict,
38-
immutabledict.immutabledict
39-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
37+
],
38+
content_type: typing_extensions.Literal["application/json"] = "application/json",
4039
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
4140
server_index: typing.Optional[int] = None,
4241
stream: bool = False,
@@ -49,9 +48,8 @@ def _client_model(
4948
self,
5049
body: typing.Union[
5150
request_body.request_body_client.content.application_json.schema.client.ClientDict,
52-
dict,
53-
immutabledict.immutabledict
54-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
51+
],
52+
content_type: typing_extensions.Literal["application/json"] = "application/json",
5553
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
5654
server_index: typing.Optional[int] = None,
5755
stream: bool = False,
@@ -63,9 +61,8 @@ def _client_model(
6361
self,
6462
body: typing.Union[
6563
request_body.request_body_client.content.application_json.schema.client.ClientDict,
66-
dict,
67-
immutabledict.immutabledict
68-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
64+
],
65+
content_type: typing_extensions.Literal["application/json"] = "application/json",
6966
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
7067
server_index: typing.Optional[int] = None,
7168
stream: bool = False,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake/post/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,8 @@ def _endpoint_parameters(
4141
body: typing.Union[
4242
request_body.content.application_x_www_form_urlencoded.schema.SchemaDict,
4343
schemas.Unset,
44-
dict,
45-
immutabledict.immutabledict
46-
] = schemas.unset, content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
44+
] = schemas.unset,
45+
content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
4746
security_index: typing.Optional[int] = None,
4847
server_index: typing.Optional[int] = None,
4948
stream: bool = False,
@@ -57,9 +56,8 @@ def _endpoint_parameters(
5756
body: typing.Union[
5857
request_body.content.application_x_www_form_urlencoded.schema.SchemaDict,
5958
schemas.Unset,
60-
dict,
61-
immutabledict.immutabledict
62-
] = schemas.unset, content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
59+
] = schemas.unset,
60+
content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
6361
security_index: typing.Optional[int] = None,
6462
server_index: typing.Optional[int] = None,
6563
stream: bool = False,
@@ -72,9 +70,8 @@ def _endpoint_parameters(
7270
body: typing.Union[
7371
request_body.content.application_x_www_form_urlencoded.schema.SchemaDict,
7472
schemas.Unset,
75-
dict,
76-
immutabledict.immutabledict
77-
] = schemas.unset, content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
73+
] = schemas.unset,
74+
content_type: typing_extensions.Literal["application/x-www-form-urlencoded"] = "application/x-www-form-urlencoded",
7875
security_index: typing.Optional[int] = None,
7976
server_index: typing.Optional[int] = None,
8077
stream: bool = False,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake_additional_properties_with_array_of_enums/get/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,8 @@ def _additional_properties_with_array_of_enums(
3535
body: typing.Union[
3636
request_body.content.application_json.schema.additional_properties_with_array_of_enums.AdditionalPropertiesWithArrayOfEnumsDict,
3737
schemas.Unset,
38-
dict,
39-
immutabledict.immutabledict
40-
] = schemas.unset, content_type: typing_extensions.Literal["application/json"] = "application/json",
38+
] = schemas.unset,
39+
content_type: typing_extensions.Literal["application/json"] = "application/json",
4140
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
4241
server_index: typing.Optional[int] = None,
4342
stream: bool = False,
@@ -51,9 +50,8 @@ def _additional_properties_with_array_of_enums(
5150
body: typing.Union[
5251
request_body.content.application_json.schema.additional_properties_with_array_of_enums.AdditionalPropertiesWithArrayOfEnumsDict,
5352
schemas.Unset,
54-
dict,
55-
immutabledict.immutabledict
56-
] = schemas.unset, content_type: typing_extensions.Literal["application/json"] = "application/json",
53+
] = schemas.unset,
54+
content_type: typing_extensions.Literal["application/json"] = "application/json",
5755
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
5856
server_index: typing.Optional[int] = None,
5957
stream: bool = False,
@@ -66,9 +64,8 @@ def _additional_properties_with_array_of_enums(
6664
body: typing.Union[
6765
request_body.content.application_json.schema.additional_properties_with_array_of_enums.AdditionalPropertiesWithArrayOfEnumsDict,
6866
schemas.Unset,
69-
dict,
70-
immutabledict.immutabledict
71-
] = schemas.unset, content_type: typing_extensions.Literal["application/json"] = "application/json",
67+
] = schemas.unset,
68+
content_type: typing_extensions.Literal["application/json"] = "application/json",
7269
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
7370
server_index: typing.Optional[int] = None,
7471
stream: bool = False,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake_body_with_file_schema/put/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,8 @@ def _body_with_file_schema(
3030
self,
3131
body: typing.Union[
3232
request_body.content.application_json.schema.file_schema_test_class.FileSchemaTestClassDict,
33-
dict,
34-
immutabledict.immutabledict
35-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
33+
],
34+
content_type: typing_extensions.Literal["application/json"] = "application/json",
3635
server_index: typing.Optional[int] = None,
3736
stream: bool = False,
3837
timeout: typing.Optional[typing.Union[int, float, typing.Tuple]] = None,
@@ -44,9 +43,8 @@ def _body_with_file_schema(
4443
self,
4544
body: typing.Union[
4645
request_body.content.application_json.schema.file_schema_test_class.FileSchemaTestClassDict,
47-
dict,
48-
immutabledict.immutabledict
49-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
46+
],
47+
content_type: typing_extensions.Literal["application/json"] = "application/json",
5048
server_index: typing.Optional[int] = None,
5149
stream: bool = False,
5250
timeout: typing.Optional[typing.Union[int, float, typing.Tuple]] = None,
@@ -57,9 +55,8 @@ def _body_with_file_schema(
5755
self,
5856
body: typing.Union[
5957
request_body.content.application_json.schema.file_schema_test_class.FileSchemaTestClassDict,
60-
dict,
61-
immutabledict.immutabledict
62-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
58+
],
59+
content_type: typing_extensions.Literal["application/json"] = "application/json",
6360
server_index: typing.Optional[int] = None,
6461
stream: bool = False,
6562
timeout: typing.Optional[typing.Union[int, float, typing.Tuple]] = None,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake_body_with_query_params/put/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,8 @@ def _body_with_query_params(
5454
self,
5555
body: typing.Union[
5656
request_body.content.application_json.schema.user.UserDict,
57-
dict,
58-
immutabledict.immutabledict
59-
], query_params: RequestQueryParameters.Params,
57+
],
58+
query_params: RequestQueryParameters.Params,
6059
content_type: typing_extensions.Literal["application/json"] = "application/json",
6160
server_index: typing.Optional[int] = None,
6261
stream: bool = False,
@@ -69,9 +68,8 @@ def _body_with_query_params(
6968
self,
7069
body: typing.Union[
7170
request_body.content.application_json.schema.user.UserDict,
72-
dict,
73-
immutabledict.immutabledict
74-
], query_params: RequestQueryParameters.Params,
71+
],
72+
query_params: RequestQueryParameters.Params,
7573
content_type: typing_extensions.Literal["application/json"] = "application/json",
7674
server_index: typing.Optional[int] = None,
7775
stream: bool = False,
@@ -83,9 +81,8 @@ def _body_with_query_params(
8381
self,
8482
body: typing.Union[
8583
request_body.content.application_json.schema.user.UserDict,
86-
dict,
87-
immutabledict.immutabledict
88-
], query_params: RequestQueryParameters.Params,
84+
],
85+
query_params: RequestQueryParameters.Params,
8986
content_type: typing_extensions.Literal["application/json"] = "application/json",
9087
server_index: typing.Optional[int] = None,
9188
stream: bool = False,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake_classname_test/patch/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,9 +39,8 @@ def _classname(
3939
self,
4040
body: typing.Union[
4141
request_body.request_body_client.content.application_json.schema.client.ClientDict,
42-
dict,
43-
immutabledict.immutabledict
44-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
42+
],
43+
content_type: typing_extensions.Literal["application/json"] = "application/json",
4544
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
4645
security_index: typing.Optional[int] = None,
4746
server_index: typing.Optional[int] = None,
@@ -55,9 +54,8 @@ def _classname(
5554
self,
5655
body: typing.Union[
5756
request_body.request_body_client.content.application_json.schema.client.ClientDict,
58-
dict,
59-
immutabledict.immutabledict
60-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
57+
],
58+
content_type: typing_extensions.Literal["application/json"] = "application/json",
6159
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
6260
security_index: typing.Optional[int] = None,
6361
server_index: typing.Optional[int] = None,
@@ -70,9 +68,8 @@ def _classname(
7068
self,
7169
body: typing.Union[
7270
request_body.request_body_client.content.application_json.schema.client.ClientDict,
73-
dict,
74-
immutabledict.immutabledict
75-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
71+
],
72+
content_type: typing_extensions.Literal["application/json"] = "application/json",
7673
accept_content_types: typing.Tuple[str, ...] = _all_accept_content_types,
7774
security_index: typing.Optional[int] = None,
7875
server_index: typing.Optional[int] = None,

samples/openapi3/client/petstore/python/src/petstore_api/paths/fake_inline_additional_properties/post/operation.py

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,8 @@ def _inline_additional_properties(
3030
self,
3131
body: typing.Union[
3232
request_body.content.application_json.schema.SchemaDict,
33-
dict,
34-
immutabledict.immutabledict
35-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
33+
],
34+
content_type: typing_extensions.Literal["application/json"] = "application/json",
3635
server_index: typing.Optional[int] = None,
3736
stream: bool = False,
3837
timeout: typing.Optional[typing.Union[int, float, typing.Tuple]] = None,
@@ -44,9 +43,8 @@ def _inline_additional_properties(
4443
self,
4544
body: typing.Union[
4645
request_body.content.application_json.schema.SchemaDict,
47-
dict,
48-
immutabledict.immutabledict
49-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
46+
],
47+
content_type: typing_extensions.Literal["application/json"] = "application/json",
5048
server_index: typing.Optional[int] = None,
5149
stream: bool = False,
5250
timeout: typing.Optional[typing.Union[int, float, typing.Tuple]] = None,
@@ -57,9 +55,8 @@ def _inline_additional_properties(
5755
self,
5856
body: typing.Union[
5957
request_body.content.application_json.schema.SchemaDict,
60-
dict,
61-
immutabledict.immutabledict
62-
], content_type: typing_extensions.Literal["application/json"] = "application/json",
58+
],
59+
content_type: typing_extensions.Literal["application/json"] = "application/json",
6360
server_index: typing.Optional[int] = None,
6461
stream: bool = False,
6562
timeout: typing.Optional[typing.Union[int, float, typing.Tuple]] = None,

0 commit comments

Comments
 (0)