# HG changeset patch # User Edouard Tisserant # Date 1328206969 -3600 # Node ID 6818cc935ab17f9bbb292e861cf45bd607c1748c # Parent 17d9c07369350ddf1df95f206de367dc14f9d8b1 [ canfestival-Bugs-3458203 ] Objdictedit diff -r 17d9c0736935 -r 6818cc935ab1 objdictgen/eds_utils.py --- a/objdictgen/eds_utils.py Wed Feb 01 18:07:04 2012 +0100 +++ b/objdictgen/eds_utils.py Thu Feb 02 19:22:49 2012 +0100 @@ -379,19 +379,19 @@ required = set(ENTRY_TYPES[values["OBJECTTYPE"]]["require"]) # Verify that parameters defined contains all the parameters required if not keys.issuperset(required): - missing = required.difference(keys)._data.keys() + missing = required.difference(keys) if len(missing) > 1: attributes = _("Attributes %s are")%_(", ").join(["\"%s\""%attribute for attribute in missing]) else: - attributes = _("Attribute \"%s\" is")%missing[0] + attributes = _("Attribute \"%s\" is")%missing.pop() raise SyntaxError, _("Error on section \"[%s]\":\n%s required for a %s entry")%(section_name, attributes, ENTRY_TYPES[values["OBJECTTYPE"]]["name"]) # Verify that parameters defined are all in the possible parameters if not keys.issubset(possible): - unsupported = keys.difference(possible)._data.keys() + unsupported = keys.difference(possible) if len(unsupported) > 1: attributes = _("Attributes %s are")%_(", ").join(["\"%s\""%attribute for attribute in unsupported]) else: - attributes = _("Attribute \"%s\" is")%unsupported[0] + attributes = _("Attribute \"%s\" is")%unsupported.pop() raise SyntaxError, _("Error on section \"[%s]\":\n%s unsupported for a %s entry")%(section_name, attributes, ENTRY_TYPES[values["OBJECTTYPE"]]["name"]) VerifyValue(values, section_name, "ParameterValue")