diff --git a/swh/lister/gitlab/lister.py b/swh/lister/gitlab/lister.py index 3f0ed96..494a5d3 100644 --- a/swh/lister/gitlab/lister.py +++ b/swh/lister/gitlab/lister.py @@ -6,10 +6,10 @@ import re import time from ..core.indexing_lister import SWHIndexingHttpLister -from .models import GitlabModel +from .models import GitLabModel -class GitlabLister(SWHIndexingHttpLister): +class GitLabLister(SWHIndexingHttpLister): # Path to give and mentioning the last id for the next page PATH_TEMPLATE = '/projects?page=%d' # gitlab api do not have an indexable identifier so using the page @@ -19,7 +19,7 @@ class GitlabLister(SWHIndexingHttpLister): # query is not part of the lookup query. So, we cannot filter # (method filter_before_inject), nor detect and disable origins # (method disable_deleted_repo_tasks) - MODEL = GitlabModel + MODEL = GitLabModel def filter_before_inject(self, models_list): """We cannot filter so returns the models_list as is. diff --git a/swh/lister/gitlab/models.py b/swh/lister/gitlab/models.py index b1c538b..65b7287 100644 --- a/swh/lister/gitlab/models.py +++ b/swh/lister/gitlab/models.py @@ -7,7 +7,7 @@ from sqlalchemy import Column, Boolean, Integer from ..core.models import ModelBase -class GitlabModel(ModelBase): +class GitLabModel(ModelBase): """a Gitlab repository""" __tablename__ = 'main_gitlab_repos' diff --git a/swh/lister/gitlab/tasks.py b/swh/lister/gitlab/tasks.py index 6686104..a8ca30a 100644 --- a/swh/lister/gitlab/tasks.py +++ b/swh/lister/gitlab/tasks.py @@ -6,23 +6,23 @@ from swh.lister.core.tasks import (IndexingDiscoveryListerTask, IndexingRangeListerTask, IndexingRefreshListerTask, ListerTaskBase) -from .lister import GitlabLister +from .lister import GitLabLister -class GitlabDotComListerTask(ListerTaskBase): +class GitLabDotComListerTask(ListerTaskBase): def new_lister(self): - return GitlabLister(lister_name='gitlab.com', + return GitLabLister(lister_name='gitlab.com', api_baseurl='https://gitlab.com/api/v4') -class IncrementalGitlabDotComLister(GitlabDotComListerTask, +class IncrementalGitLabDotComLister(GitLabDotComListerTask, IndexingDiscoveryListerTask): task_queue = 'swh_lister_gitlab_discover' -class RangeGitlabLister(GitlabDotComListerTask, IndexingRangeListerTask): +class RangeGitLabLister(GitLabDotComListerTask, IndexingRangeListerTask): task_queue = 'swh_lister_gitlab_refresh' -class FullGitlabRelister(GitlabDotComListerTask, IndexingRefreshListerTask): +class FullGitLabRelister(GitLabDotComListerTask, IndexingRefreshListerTask): task_queue = 'swh_lister_gitlab_refresh'