[Python] Fixed docstrings in api.mustache (#6391)

* [Python] Fixed docstrings

Fixes https://github.com/swagger-api/swagger-codegen/issues/9630

* Updated generated files

* Fixed python-experimental

* Updated generated files

* Fully fixed the format of the docstrings

* Updated generated files

* Updated generated files in openapi3
This commit is contained in:
Alexey Volkov
2020-06-04 08:46:35 -07:00
committed by GitHub
parent e708cdc83e
commit 6f6c8ede79
240 changed files with 3920 additions and 1882 deletions

View File

@@ -1 +1 @@
4.3.0-SNAPSHOT
5.0.0-SNAPSHOT

View File

@@ -17,7 +17,7 @@ def add_pet(pet): # noqa: E501
:param pet: Pet object that needs to be added to the store
:type pet: dict | bytes
:rtype: Pet
:rtype: None
"""
if connexion.request.is_json:
pet = Pet.from_dict(connexion.request.get_json()) # noqa: E501
@@ -86,7 +86,7 @@ def update_pet(pet): # noqa: E501
:param pet: Pet object that needs to be added to the store
:type pet: dict | bytes
:rtype: Pet
:rtype: None
"""
if connexion.request.is_json:
pet = Pet.from_dict(connexion.request.get_json()) # noqa: E501

View File

@@ -26,15 +26,6 @@ paths:
requestBody:
$ref: '#/components/requestBodies/Pet'
responses:
"200":
content:
application/xml:
schema:
$ref: '#/components/schemas/Pet'
application/json:
schema:
$ref: '#/components/schemas/Pet'
description: successful operation
"405":
description: Invalid input
security:
@@ -50,15 +41,6 @@ paths:
requestBody:
$ref: '#/components/requestBodies/Pet'
responses:
"200":
content:
application/xml:
schema:
$ref: '#/components/schemas/Pet'
application/json:
schema:
$ref: '#/components/schemas/Pet'
description: successful operation
"400":
description: Invalid ID supplied
"404":

View File

@@ -41,7 +41,6 @@ class TestPetController(BaseTestCase):
"status" : "available"
}
headers = {
'Accept': 'application/json',
'Content-Type': 'application/json',
'Authorization': 'Bearer special-key',
}
@@ -146,7 +145,6 @@ class TestPetController(BaseTestCase):
"status" : "available"
}
headers = {
'Accept': 'application/json',
'Content-Type': 'application/json',
'Authorization': 'Bearer special-key',
}

View File

@@ -1,7 +1,10 @@
connexion >= 2.6.0; python_version>="3.6"
connexion >= 2.3.0; python_version=="3.5"
connexion >= 2.3.0; python_version=="3.4"
connexion == 2.4.0; python_version<="2.7"
connexion[swagger-ui] >= 2.6.0; python_version>="3.6"
# 2.3 is the last version that supports python 3.4-3.5
connexion[swagger-ui] <= 2.3.0; python_version=="3.5" or python_version=="3.4"
# connexion requires werkzeug but connexion < 2.4.0 does not install werkzeug
# we must peg werkzeug versions below to fix connexion
# https://github.com/zalando/connexion/pull/1044
werkzeug == 0.16.1; python_version=="3.5" or python_version=="3.4"
swagger-ui-bundle >= 0.0.2
python_dateutil >= 2.6.0
setuptools >= 21.0.0

View File

@@ -1,4 +1,4 @@
pytest~=4.6.7 # needed for python 2.7+3.4
pytest-cov>=2.8.1
pytest-randomly==1.2.3 # needed for python 2.7+3.4
flask_testing==0.6.1
Flask-Testing==0.8.0

View File

@@ -1,9 +1,11 @@
[tox]
envlist = py3
skipsdist=True
[testenv]
deps=-r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
{toxinidir}
commands=
pytest --cov=openapi_server
pytest --cov=openapi_server