Revision 68b2e985 lib/opcodes.py
b/lib/opcodes.py | ||
---|---|---|
468 | 468 |
if set_defaults or hasattr(self, attr_name): |
469 | 469 |
attr_val = getattr(self, attr_name) |
470 | 470 |
if not test(attr_val): |
471 |
logging.error("OpCode %s, parameter %s, has invalid type %s/value %s", |
|
472 |
self.OP_ID, attr_name, type(attr_val), attr_val) |
|
471 |
logging.error("OpCode %s, parameter %s, has invalid type %s/value %s" |
|
472 |
" expecting type %s", |
|
473 |
self.OP_ID, attr_name, type(attr_val), attr_val, test) |
|
473 | 474 |
raise errors.OpPrereqError("Parameter '%s.%s' fails validation" % |
474 | 475 |
(self.OP_ID, attr_name), |
475 | 476 |
errors.ECODE_INVAL) |
Also available in: Unified diff