From 417b1541351d716b84d909a9f164fcfb206a820f Mon Sep 17 00:00:00 2001 From: Sanjiban Sengupta Date: Tue, 17 Oct 2023 04:54:51 +0530 Subject: [PATCH] feat: sort imports using isort --- api/app.py | 29 ++++++++++------------------- api/backend/duckdb.py | 1 - api/test.py | 4 +++- 3 files changed, 13 insertions(+), 21 deletions(-) diff --git a/api/app.py b/api/app.py index 570af700..c97dce52 100644 --- a/api/app.py +++ b/api/app.py @@ -1,28 +1,19 @@ -from fastapi import FastAPI, HTTPException, status, Depends, File, UploadFile, Form +import json + +import jwt +import substrait_validator as sv +from duckdb import DuckDBPyConnection +from fastapi import (Depends, FastAPI, File, Form, HTTPException, UploadFile, + status) from fastapi.middleware.trustedhost import TrustedHostMiddleware from fastapi.openapi.utils import get_openapi from fastapi.security import OAuth2PasswordBearer from fastapi_health import health -import jwt - -import json - -from duckdb import DuckDBPyConnection - -import substrait_validator as sv - -from backend.duckdb import ( - DuckDBConnection, - CheckDuckDBConnection, - ExecuteDuckDb, - ParseFromDuckDB, - DeleteTableFromDuckDB, -) - -from backend.ttl_cache import TTL_Cache - from loguru import logger +from backend.duckdb import (CheckDuckDBConnection, DeleteTableFromDuckDB, + DuckDBConnection, ExecuteDuckDb, ParseFromDuckDB) +from backend.ttl_cache import TTL_Cache app = FastAPI() diff --git a/api/backend/duckdb.py b/api/backend/duckdb.py index 23fa23b6..2f6bb69a 100644 --- a/api/backend/duckdb.py +++ b/api/backend/duckdb.py @@ -1,6 +1,5 @@ import duckdb from fastapi import HTTPException - from loguru import logger diff --git a/api/test.py b/api/test.py index a7068810..949335f4 100644 --- a/api/test.py +++ b/api/test.py @@ -1,6 +1,8 @@ -from fastapi.testclient import TestClient from io import BytesIO + import requests +from fastapi.testclient import TestClient + from app import app client = TestClient(app)