31,32c31,32
< from attrdict import attrdict, optiondict
< from misc import crossproduct, flatten
---
> from attrdict import optiondict
> from misc import crossproduct
44,46c44,66
< for k,v in obj.__dict__.iteritems():
< if not k.startswith('_'):
< self.__dict__[k] = v
---
> for key,val in obj.__dict__.iteritems():
> if key.startswith('_') or key in ('name', 'desc'):
> continue
>
> if key not in self.__dict__:
> self.__dict__[key] = val
> continue
>
> if not isinstance(val, dict):
> if self.__dict__[key] == val:
> continue
>
> raise AttributeError, \
> "%s specified more than once old: %s new: %s" % \
> (key, self.__dict__[key], val)
>
> d = self.__dict__[key]
> for k,v in val.iteritems():
> if k in d:
> raise AttributeError, \
> "%s specified more than once in %s" % (k, key)
> d[k] = v
>
95a116,123
> def __repr__(self):
> d = {}
> for key,value in self.__dict__.iteritems():
> if not key.startswith('_'):
> d[key] = value
>
> return "<%s: %s>" % (type(self).__name__, d)
>
394,400c422
< conf = data['conf']
< import jobfile
< if not isinstance(conf, Configuration):
< raise AttributeError, \
< 'conf in jobfile: %s (%s) is not type %s' % \
< (jobfile, type(conf), Configuration)
< return conf
---
> return data['conf']
403c425,427
< import sys
---
> usage = 'Usage: %s [-b] [-c] [-v]' % sys.argv[0]
> if conf is None:
> usage += ' <jobfile>'
405,406d428
< usage = 'Usage: %s [-b] [-c] [-v] <jobfile>' % sys.argv[0]
<