"Hugo Arts" <hugo.yo...@gmail.com> wrote
Side question: Any reason why you'd raise the exception from __new__
rather than __init__? If you want to return None, then yeah I can
see
why you'd have to use __new__, but would there be any reason you
can't
or shouldn't simply raise an exception from __init__?
Because by the time you get to init you have already created
the instance. If you really want to avoid creating an instance it
needs to be in new.
Alan G
_______________________________________________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor