Joe Strout wrote:
So, in this case, the simplest solution was to have the method that initially accepts and stores the data check to make sure that data satisfies the assumptions of the class.
In hindsight, yes, but the trouble is that you can't tell ahead of time which of the gazillion places in the code that where you store things away in containers are likely to cause a problem later. I can't imagine myself writing code to check every argument to every method to guard against this sort of thing. If you're willing to do that, it's up to you, but it's far from common practice in Python programming. -- Greg -- http://mail.python.org/mailman/listinfo/python-list