python: Reorder imports with isort

Related to T2610
This commit is contained in:
Antoine Lambert 2020-09-17 17:47:55 +02:00
parent d24846a957
commit 22f7181294
69 changed files with 136 additions and 168 deletions

View file

@ -4,8 +4,8 @@
def register():
from .models import NpmVisitModel, NpmModel
from .lister import NpmLister
from .models import NpmModel, NpmVisitModel
return {
"models": [NpmVisitModel, NpmModel],

View file

@ -2,13 +2,14 @@
# License: GNU General Public License version 3, or any later version
# See top-level LICENSE file for more information
from typing import Any, Dict, List, Optional
from requests import Response
from swh.lister.core.indexing_lister import IndexingHttpLister
from swh.lister.npm.models import NpmModel
from swh.scheduler.utils import create_task_dict
from typing import Any, Dict, Optional, List
from requests import Response
class NpmListerBase(IndexingHttpLister):
"""List packages available in the npm registry in a paginated way

View file

@ -2,9 +2,9 @@
# License: GNU General Public License version 3, or any later version
# See top-level LICENSE file for more information
from sqlalchemy import Column, String, DateTime, Integer, BigInteger, Sequence
from sqlalchemy import BigInteger, Column, DateTime, Integer, Sequence, String
from swh.lister.core.models import IndexingModelBase, SQLBase, ABCSQLMeta
from swh.lister.core.models import ABCSQLMeta, IndexingModelBase, SQLBase
class NpmVisitModel(SQLBase, metaclass=ABCSQLMeta):

View file

@ -2,12 +2,12 @@
# License: GNU General Public License version 3, or any later version
# See top-level LICENSE file for more information
from datetime import datetime
from contextlib import contextmanager
from datetime import datetime
from celery import shared_task
from swh.lister.npm.lister import NpmLister, NpmIncrementalLister
from swh.lister.npm.lister import NpmIncrementalLister, NpmLister
from swh.lister.npm.models import NpmVisitModel

View file

@ -4,16 +4,14 @@
# See top-level LICENSE file for more information
import logging
import re
import requests_mock
from typing import Any, List
import unittest
import requests_mock
from swh.lister.core.tests.test_lister import HttpListerTesterBase
from swh.lister.npm.lister import NpmLister, NpmIncrementalLister
from typing import Any, List
from swh.lister.npm.lister import NpmIncrementalLister, NpmLister
logger = logging.getLogger(__name__)