From 198bf2265551dd3917b9be0eb36b4972dae096f2 Mon Sep 17 00:00:00 2001 From: Evan Blaudy Date: Wed, 7 Aug 2024 16:08:59 +0200 Subject: [PATCH] [qa] autoflake --- gazu/exception.py | 22 ---------------------- tests/test_client.py | 3 +-- tests/test_context.py | 2 +- tests/test_edit.py | 2 -- tests/test_project.py | 1 - tests/test_task.py | 1 - 6 files changed, 2 insertions(+), 29 deletions(-) diff --git a/gazu/exception.py b/gazu/exception.py index 4f58cb6b..abb87a1b 100644 --- a/gazu/exception.py +++ b/gazu/exception.py @@ -3,64 +3,48 @@ class HostException(Exception): Error raised when host is not valid. """ - pass - class AuthFailedException(Exception): """ Error raised when user credentials are wrong. """ - pass - class NotAuthenticatedException(Exception): """ Error raised when a 401 error (not authenticated) is sent by the API. """ - pass - class NotAllowedException(Exception): """ Error raised when a 403 error (not authorized) is sent by the API. """ - pass - class MethodNotAllowedException(Exception): """ Error raised when a 405 error (method not handled) is sent by the API. """ - pass - class RouteNotFoundException(Exception): """ Error raised when a 404 error (not found) is sent by the API. """ - pass - class ServerErrorException(Exception): """ Error raised when a 500 error (server error) is sent by the API. """ - pass - class ParameterException(Exception): """ Error raised when a 400 error (argument error) is sent by the API. """ - pass - class UploadFailedException(Exception): """ @@ -68,24 +52,18 @@ class UploadFailedException(Exception): where processing that occurs on the remote server fails. """ - pass - class TooBigFileException(Exception): """ Error raised when a 413 error (payload too big error) is sent by the API. """ - pass - class TaskStatusNotFoundException(Exception): """ Error raised when a task status is not found. """ - pass - class DownloadFileException(Exception): """ diff --git a/tests/test_client.py b/tests/test_client.py index f509ac01..5fdb6a9a 100644 --- a/tests/test_client.py +++ b/tests/test_client.py @@ -1,13 +1,12 @@ import datetime import json -import sys import unittest import requests_mock import gazu from gazu.__version__ import __version__ -from gazu import client as raw, set_event_host +from gazu import client as raw from gazu.exception import ( RouteNotFoundException, AuthFailedException, diff --git a/tests/test_context.py b/tests/test_context.py index ee7540a4..8e290d1f 100644 --- a/tests/test_context.py +++ b/tests/test_context.py @@ -7,7 +7,7 @@ import gazu.shot import gazu.project import requests_mock -from utils import mock_route, fakeid +from utils import mock_route class CastingTestCase(unittest.TestCase): diff --git a/tests/test_edit.py b/tests/test_edit.py index db598960..79db3d42 100644 --- a/tests/test_edit.py +++ b/tests/test_edit.py @@ -1,7 +1,5 @@ import unittest -import json import requests_mock -import os import gazu.client import gazu.edit diff --git a/tests/test_project.py b/tests/test_project.py index 968d42e7..e90db6bd 100644 --- a/tests/test_project.py +++ b/tests/test_project.py @@ -1,4 +1,3 @@ -from gazu.helpers import normalize_model_parameter import unittest import requests_mock import gazu.client diff --git a/tests/test_task.py b/tests/test_task.py index 62720d05..08956cd2 100644 --- a/tests/test_task.py +++ b/tests/test_task.py @@ -1,4 +1,3 @@ -from re import T import unittest import json import requests_mock