Skip to content

Commit a27bee0

Browse files
mdesmethashhar
authored andcommitted
Sort imports using isort
1 parent 1849b96 commit a27bee0

24 files changed

+77
-73
lines changed

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
import re
1717
import textwrap
1818

19-
from setuptools import setup, find_packages
19+
from setuptools import find_packages, setup
2020

2121
_version_re = re.compile(r"__version__\s+=\s+(.*)")
2222

tests/integration/conftest.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@
1818
from uuid import uuid4
1919

2020
import click
21-
import trino.logging
2221
import pytest
23-
from trino.client import TrinoQuery, TrinoRequest, ClientSession
24-
from trino.constants import DEFAULT_PORT
2522

23+
import trino.logging
24+
from trino.client import ClientSession, TrinoQuery, TrinoRequest
25+
from trino.constants import DEFAULT_PORT
2626

2727
logger = trino.logging.get_logger(__name__)
2828

tests/integration/test_dbapi_integration.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
# See the License for the specific language governing permissions and
1111
# limitations under the License.
1212
import math
13-
from datetime import datetime, time, date, timezone, timedelta
13+
from datetime import date, datetime, time, timedelta, timezone
1414
from decimal import Decimal
1515

1616
import pytest
@@ -20,7 +20,7 @@
2020
import trino
2121
from tests.integration.conftest import trino_version
2222
from trino import constants
23-
from trino.exceptions import TrinoQueryError, TrinoUserError, NotSupportedError
23+
from trino.exceptions import NotSupportedError, TrinoQueryError, TrinoUserError
2424
from trino.transaction import IsolationLevel
2525

2626

tests/integration/test_sqlalchemy_integration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
# limitations under the License
1212
import pytest
1313
import sqlalchemy as sqla
14-
from sqlalchemy.sql import and_, or_, not_
14+
from sqlalchemy.sql import and_, not_, or_
1515
from sqlalchemy_utils import create_view
1616

1717
from tests.unit.conftest import sqlalchemy_version

tests/integration/test_types_integration.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import math
2-
import pytest
32
from decimal import Decimal
3+
4+
import pytest
5+
46
import trino
57

68

tests/unit/conftest.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,10 @@
1010
# See the License for the specific language governing permissions and
1111
# limitations under the License.
1212

13-
import pytest
1413
from unittest.mock import MagicMock, patch
1514

15+
import pytest
16+
1617

1718
@pytest.fixture(scope="session")
1819
def sample_post_response_data():

tests/unit/sqlalchemy/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
import pytest
1313
from sqlalchemy.sql.sqltypes import ARRAY
1414

15-
from trino.sqlalchemy.datatype import MAP, ROW, SQLType, TIMESTAMP, TIME
15+
from trino.sqlalchemy.datatype import MAP, ROW, TIME, TIMESTAMP, SQLType
1616

1717

1818
@pytest.fixture(scope="session")

tests/unit/sqlalchemy/test_compiler.py

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,7 @@
1010
# See the License for the specific language governing permissions and
1111
# limitations under the License.
1212
import pytest
13-
from sqlalchemy import (
14-
Column,
15-
insert,
16-
Integer,
17-
MetaData,
18-
select,
19-
String,
20-
Table,
21-
)
13+
from sqlalchemy import Column, Integer, MetaData, String, Table, insert, select
2214
from sqlalchemy.schema import CreateTable
2315
from sqlalchemy.sql import column, table
2416

tests/unit/sqlalchemy/test_datatype_parse.py

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -11,23 +11,11 @@
1111
# limitations under the License.
1212
import pytest
1313
from sqlalchemy.exc import UnsupportedCompilationError
14-
from sqlalchemy.sql.sqltypes import (
15-
CHAR,
16-
VARCHAR,
17-
ARRAY,
18-
INTEGER,
19-
DECIMAL,
20-
DATE
21-
)
14+
from sqlalchemy.sql.sqltypes import ARRAY, CHAR, DATE, DECIMAL, INTEGER, VARCHAR
2215
from sqlalchemy.sql.type_api import TypeEngine
2316

2417
from trino.sqlalchemy import datatype
25-
from trino.sqlalchemy.datatype import (
26-
MAP,
27-
ROW,
28-
TIME,
29-
TIMESTAMP
30-
)
18+
from trino.sqlalchemy.datatype import MAP, ROW, TIME, TIMESTAMP
3119

3220

3321
@pytest.mark.parametrize(

tests/unit/sqlalchemy/test_dialect.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,17 @@
22
from unittest import mock
33

44
import pytest
5-
from sqlalchemy.engine.url import make_url, URL
5+
from sqlalchemy.engine.url import URL, make_url
66

77
from trino.auth import BasicAuthentication
88
from trino.dbapi import Connection
9-
from trino.sqlalchemy.dialect import CertificateAuthentication, JWTAuthentication, TrinoDialect
10-
from trino.transaction import IsolationLevel
119
from trino.sqlalchemy import URL as trino_url
10+
from trino.sqlalchemy.dialect import (
11+
CertificateAuthentication,
12+
JWTAuthentication,
13+
TrinoDialect,
14+
)
15+
from trino.transaction import IsolationLevel
1216

1317

1418
class TestTrinoDialect:

0 commit comments

Comments
 (0)