From c4290ee96b3427551e1ba17886b25118880fed00 Mon Sep 17 00:00:00 2001 From: Joao Daher Date: Sun, 7 Mar 2021 07:58:38 -0300 Subject: [PATCH] Update sanic references --- flamingo/main.py | 4 +++- flamingo/models/build.py | 2 +- flamingo/models/repository.py | 2 +- flamingo/views/app_views.py | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/flamingo/main.py b/flamingo/main.py index ce49241..d168104 100755 --- a/flamingo/main.py +++ b/flamingo/main.py @@ -1,6 +1,9 @@ # pylint: disable=wrong-import-position import os import sys + +from sanic_rest import exceptions + sys.path.append(os.path.dirname(__file__)) from sanic import Sanic @@ -8,7 +11,6 @@ import settings import views -import exceptions app = Sanic(name='flamingo', error_handler=exceptions.rest_error_handler) app.update_config(settings) diff --git a/flamingo/models/build.py b/flamingo/models/build.py index dd51731..03d7b99 100644 --- a/flamingo/models/build.py +++ b/flamingo/models/build.py @@ -2,8 +2,8 @@ from typing import List from gcp_pilot.datastore import EmbeddedDocument +from sanic_rest import exceptions -import exceptions import settings from models.buildpack import BuildPack from models.label import Label diff --git a/flamingo/models/repository.py b/flamingo/models/repository.py index 0cab35b..bc18c4e 100644 --- a/flamingo/models/repository.py +++ b/flamingo/models/repository.py @@ -3,8 +3,8 @@ from gcp_pilot.build import AnyEventType, CloudBuild from gcp_pilot.datastore import EmbeddedDocument from github import Github +from sanic_rest import exceptions -import exceptions import settings from models.project import Project diff --git a/flamingo/views/app_views.py b/flamingo/views/app_views.py index 791a4e7..c718dd8 100644 --- a/flamingo/views/app_views.py +++ b/flamingo/views/app_views.py @@ -2,8 +2,8 @@ from sanic import Blueprint from sanic.request import Request +from sanic_rest import exceptions -import exceptions from models.app import App from models.database import Database from models.env_var import EnvVar