From f494bb1502eee1afe54660421679b8c21ed57a5e Mon Sep 17 00:00:00 2001 From: Daniel Dehennin Date: Wed, 30 Jan 2013 18:04:25 +0100 Subject: [PATCH] Better raise message * tiramisu/config.py (Config._valid_len): use master and slave name and value. --- tiramisu/config.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tiramisu/config.py b/tiramisu/config.py index 9e254d9..afad3d5 100644 --- a/tiramisu/config.py +++ b/tiramisu/config.py @@ -199,8 +199,12 @@ class Config(object): return True if master_len != len(slave_value): master_name = self._cfgimpl_descr.get_master_name() - raise ValueError("invalid len for the group of" - " the option {0}".format(slave_name)) + master_value = self._cfgimpl_values[master_name] + raise ValueError("invalid len of '{0}={1}' for the group of" + " '{2}={3}'".format(slave_name, + slave_value, + master_name, + master_value)) def fill_multi(self, name, result, use_default_multi=False, default_multi=None): """fills a multi option with default and calculated values