Matej Cepl wrote: > Now, my question is concerned with the use of exception in SoupReader.suck. > The idea is that when the page is not available for download, whole object > goes up in flames, the rest of SoapReader.__init__ is skipped over, and the > exception is then caught in reprocess.py cycle, which makes a note in some > errorlog, that this particular page has not been downloaded, but otherwise > the script continues for other pages. Is it what I am doing here or did I > missed the idea of exceptions at all?
After a quick look I think you have it right. You could define PageNotAvailable as class PageNotAvailable(Exception): pass because the behavior you give it is the default behaviour for Exception. Kent _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor