Fix uses of OpPrereqError without code info
A while back, we did cleanup the code and ensured (manually) that use of OpPrereqError includes an errors.ECODE_* field as second argument. Since we cannot automate the check for this, it turns out that more and more such usage has crept over the years, including in the master code (the use on the CLI side is not as important). Note that this also uncovered a few errors in ovf.py where the errors messages were wrongly constructed. Still looking for a way to automate this check… Signed-off-by:Iustin Pop <iustin@google.com> Reviewed-by:
Guido Trotter <ultrotter@google.com>
Showing
- lib/bootstrap.py 7 additions, 4 deletionslib/bootstrap.py
- lib/cli.py 28 additions, 20 deletionslib/cli.py
- lib/client/gnt_instance.py 2 additions, 2 deletionslib/client/gnt_instance.py
- lib/cmdlib.py 28 additions, 26 deletionslib/cmdlib.py
- lib/ovf.py 68 additions, 41 deletionslib/ovf.py
- lib/qlang.py 2 additions, 2 deletionslib/qlang.py
- lib/server/masterd.py 2 additions, 1 deletionlib/server/masterd.py
- lib/uidpool.py 2 additions, 2 deletionslib/uidpool.py
Loading
Please register or sign in to comment