libkas: Gracefully handle empty repo set
We will fail differently then, but with a nicer error message (missing init-build-env script) than ValueError: Set of coroutines/Futures is empty. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
This commit is contained in:
parent
4c81f96742
commit
8a1c27bc92
@ -163,6 +163,9 @@ def repos_fetch(repos):
|
|||||||
"""
|
"""
|
||||||
Fetches the list of repositories to the kas_work_dir.
|
Fetches the list of repositories to the kas_work_dir.
|
||||||
"""
|
"""
|
||||||
|
if len(repos) == 0:
|
||||||
|
return
|
||||||
|
|
||||||
tasks = []
|
tasks = []
|
||||||
for repo in repos:
|
for repo in repos:
|
||||||
tasks.append(asyncio.ensure_future(repo.fetch_async()))
|
tasks.append(asyncio.ensure_future(repo.fetch_async()))
|
||||||
@ -179,6 +182,9 @@ def repos_apply_patches(repos):
|
|||||||
"""
|
"""
|
||||||
Applies the patches to the repositories.
|
Applies the patches to the repositories.
|
||||||
"""
|
"""
|
||||||
|
if len(repos) == 0:
|
||||||
|
return
|
||||||
|
|
||||||
tasks = []
|
tasks = []
|
||||||
for repo in repos:
|
for repo in repos:
|
||||||
tasks.append(asyncio.ensure_future(repo.apply_patches_async()))
|
tasks.append(asyncio.ensure_future(repo.apply_patches_async()))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user