mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
frontend: report arguments errors with better detail
When reporting argument errors, show also a context -- what is processed, what is the name of the command.
This commit is contained in:
committed by
Martin Kosek
parent
0b29bfde0d
commit
2d6c7e3adb
@@ -869,7 +869,8 @@ class Command(HasParam):
|
||||
for arg in args():
|
||||
if optional and arg.required:
|
||||
raise ValueError(
|
||||
'%s: required argument after optional' % arg.name
|
||||
'%s: required argument after optional in %s arguments %s' % (arg.name,
|
||||
self.name, map(lambda x: x.param_spec, args()))
|
||||
)
|
||||
if multivalue:
|
||||
raise ValueError(
|
||||
|
||||
Reference in New Issue
Block a user