baffling error-handling problem

Michael Hudson mwh at python.net
Thu Jul 28 11:47:26 EDT 2005


Chris Fonnesbeck <fonnesbeck at gmail.com> writes:

> I thought I knew how to do error handling in python, but apparently I
> dont. I have a bunch of code to calculate statistical likelihoods, and
> use error handling to catch invalid parameters. For example, for the

[...]

> bernoulli distribution, I have:
> I have no idea how this can happen, given how I have coded this.
> Anyone see what I must be missing?

Is it possible you have two classes called LikelihoodError?  One in
__main__, one in some_module_of_yours, maybe.

Cheers,
mwh

-- 
  <bruce> how are the jails in israel?
  <itamar> well, the one I was in was pretty nice
                                                -- from Twisted.Quotes



More information about the Python-list mailing list