lister/tasks: Standardize return statements
The following commit adapts the return statements from both lister and their associated tasks. This standardizes on what other modules (e.g. both dvcs and package loaders) do.
This commit is contained in:
parent
ff7fdf24db
commit
4a9608f31c
15 changed files with 42 additions and 21 deletions
|
@ -20,13 +20,13 @@ def list_gitlab_incremental(**lister_args):
|
|||
lister = GitLabLister(**lister_args)
|
||||
total_pages = lister.get_pages_information()[1]
|
||||
# stopping as soon as existing origins for that instance are detected
|
||||
lister.run(min_bound=1, max_bound=total_pages, check_existence=True)
|
||||
return lister.run(min_bound=1, max_bound=total_pages, check_existence=True)
|
||||
|
||||
|
||||
@shared_task(name=__name__ + '.RangeGitLabLister')
|
||||
def _range_gitlab_lister(start, end, **lister_args):
|
||||
lister = GitLabLister(**lister_args)
|
||||
lister.run(min_bound=start, max_bound=end)
|
||||
return lister.run(min_bound=start, max_bound=end)
|
||||
|
||||
|
||||
@shared_task(name=__name__ + '.FullGitLabRelister', bind=True)
|
||||
|
@ -43,6 +43,7 @@ def list_gitlab_full(self, **lister_args):
|
|||
promise.save()
|
||||
except (NotImplementedError, AttributeError):
|
||||
self.log.info('Unable to call save_group with current result backend.')
|
||||
# FIXME: what to do in terms of return here?
|
||||
return promise.id
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue