cli: catch koji.ParameterError in list_task_output_all_volumes
When we send an RPC with a parameter that the hub does not understand, we get a koji.ParameterError. Update list_task_output_all_volumes() to catch the specific error we expect here. The purpose of this change is to make the code easier to understand.
This commit is contained in:
parent
ed04738b58
commit
8d0b4bc618
1 changed files with 1 additions and 1 deletions
|
|
@ -454,7 +454,7 @@ def list_task_output_all_volumes(session, task_id):
|
|||
"""List task output with all volumes, or fake it"""
|
||||
try:
|
||||
return session.listTaskOutput(task_id, all_volumes=True)
|
||||
except koji.GenericError as e:
|
||||
except koji.ParameterError as e:
|
||||
if 'got an unexpected keyword argument' not in str(e):
|
||||
raise
|
||||
# otherwise leave off the option and fake it
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue