Drop type hints they are not compatible with Py2.7

This commit is contained in:
Denis Makogon 2016-12-07 23:23:35 +02:00
parent d7e6a8eae9
commit 832e8d87e1
2 changed files with 18 additions and 18 deletions

View File

@ -18,11 +18,11 @@ class Apps(object):
apps_route = "/v1/{project_id}/apps"
app_route = "/v1/{project_id}/apps/{app}"
def __init__(self, session_client: client.SessionClient):
def __init__(self, session_client):
self.client = session_client
@client.inject_project_id
def list(self, project_id: str):
def list(self, project_id):
"""
Lists project-scoped apps
@ -34,7 +34,7 @@ class Apps(object):
return response.json()
@client.inject_project_id
def show(self, project_id: str, app_name: str):
def show(self, project_id, app_name):
"""
Shows project-scoped app info
@ -48,8 +48,8 @@ class Apps(object):
return response.json()
@client.inject_project_id
def create(self, project_id: str, app_name: str,
config: dict=None):
def create(self, project_id, app_name,
config=None):
"""
Creates project-scoped app
@ -72,7 +72,7 @@ class Apps(object):
return response.json()
@client.inject_project_id
def update(self, project_id: str, app_name: str, **data: dict):
def update(self, project_id, app_name, **data):
"""
Updates app
@ -89,7 +89,7 @@ class Apps(object):
return response.json()
@client.inject_project_id
def delete(self, project_id: str, app_name: str):
def delete(self, project_id, app_name):
"""
Deletes app

View File

@ -24,11 +24,11 @@ class Routes(object):
self.client = session_client
@client.inject_project_id
def create(self, project_id: str, app_name: str,
execution_type: str, route_path: str, image: str,
is_public: bool=False, memory: int=None,
timeout: int=None, max_concurrency: int=None,
config: dict=None):
def create(self, project_id, app_name,
execution_type, route_path, image,
is_public=False, memory=None,
timeout=None, max_concurrency=None,
config=None):
"""
Creates app route
@ -73,7 +73,7 @@ class Routes(object):
return response.json()
@client.inject_project_id
def list(self, project_id: str, app_name: str):
def list(self, project_id, app_name):
"""
Lists project-scoped app routes
@ -87,7 +87,7 @@ class Routes(object):
return response.json()
@client.inject_project_id
def show(self, project_id: str, app_name: str, route_path: str):
def show(self, project_id, app_name, route_path):
"""
Retrieves app route information
@ -104,8 +104,8 @@ class Routes(object):
return response.json()
@client.inject_project_id
def update(self, project_id: str, app_name: str,
route_path: str, **data: str):
def update(self, project_id, app_name,
route_path, **data):
"""
Updates route with provided data
@ -124,7 +124,7 @@ class Routes(object):
return response.json()
@client.inject_project_id
def delete(self, project_id: str, app_name: str, route_path: str):
def delete(self, project_id, app_name, route_path):
"""
Deletes app
@ -141,7 +141,7 @@ class Routes(object):
return response.json()
@client.inject_project_id
def execute(self, project_id: str, app_name: str, route_path: str,
def execute(self, project_id, app_name, route_path,
supply_auth_properties: bool=False, **data: dict):
"""
Runs execution against public/private routes