On Dec 22, 5:34 am, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > Russ P. wrote: > > Actually, the parens aren't needed, so this works too: > > > def __init__(self, args=""): self.args = args, > > > The trailing comma wasn't necessary a while back (pre 2.5?), so > > something in Python must have changed. I'd say that it looks a bit > > cleaner without the trailing comma, so maybe whatever changed should > > get changed back. > > as the name implies, "args" is supposed to be a sequence, and is stored > internally as a tuple. if something has changed, it's probably that 2.5 > enforces this behaviour via a property. > > to fix your code, just replace your own __init__ method with a "pass", > and leave the initialization to the Exception class itself.
That works. And because it is the simplest solution here, I'd say it's the "correct" solution. Thanks. -- http://mail.python.org/mailman/listinfo/python-list