[PEAK] dispatch Problem?

Jay Parlar parlar at gmail.com
Sat Jan 22 14:00:11 EST 2005


Thanks a lot. I won't be in at work to try it on my production machine
until Monday, but I'll make sure to let you know if there are still
any problems.


Jay P.


On Sat, 22 Jan 2005 13:57:14 -0500, Phillip J. Eby
<pje at telecommunity.com> wrote:
> At 11:47 PM 1/21/05 -0500, Phillip J. Eby wrote:
> >At 10:14 AM 1/21/05 -0500, Jay Parlar wrote:
> >>Am I doing something wrong here, or is this a bug in the dispatch module?
> >>
> >>Essentially, I want to check if an object attribute is evaluating to
> >>True or not, ie.
> >>
> >> >>> import dispatch
> >> >>> @dispatch.generic()
> >>... def foo(x): pass
> >>...
> >> >>> @foo.when("x.bar")
> >>... def foo(x): print "x.bar is some sort of true"
> 
> Okay, I've found and fixed the problem in CVS, with tests.  It had nothing
> to do with decorators; it was a problem with preserving the order of
> expressions in signatures, that was breaking the generic function used to
> process bare expressions like 'x.bar'.  I wasn't able to reproduce your
> specific problem on Windows for some reason, but I was able to reproduce it
> on Linux with either Python 2.3 or 2.4.  It was a hash-dependent issue,
> i.e. depending on the hash values it would either work or not work, so that
> might have something to do with why I couldn't reproduce on Windows.
> 
> Anyway, it's fixed; thanks for the report.
> 
>



More information about the PEAK mailing list