[PD] Patch acting weird with Pd 0.46.6

Jonathan Wilkes jancsika at yahoo.com
Fri Jun 5 04:55:27 CEST 2015


On 06/04/2015 04:03 AM, Pierre Massat wrote:
> Dear all,
>
> Just to give you my modest input on this discussion.
> I just looked at IOhannes' last patch and now I got it. The mistake I 
> made was to believe that print would send the current value to the 
> console at each step of the loop (like print in a for loop in Python 
> for instance), and that the firing order just before the print only 
> mattered at "micro" level.

This is actually a great example of what I was talking about with 
dogmatic use of trigger vs fanouts.

It sounds like Pierre was thinking that trigger would fire 
"breadth-first" before starting the next iteration of the loop.  If
he had employed a trigger in this example, he was under the impression 
that [print] would fire each iteration regardless
of which outlet of trigger it was hooked to.  He thought he could put 
the [print] before OR after the connection triggering the recursion.

So even with a dogmatic use of trigger, Pierre would have had a 50% 
chance of hitting the bug.  And that's the same chance
he had by using the fanout.

Because he did use a fanout, IOhannes' proclamation to never use them 
guided him quickly to the problem.  The irony is
if he had used a dogmatic trigger and hit the bug, it would have taken 
him longer to find since they are indistinguishable from
normal triggers.

-Jonathan

> Now of course I understand why I was wrong, after looking up depth 
> first on the web.
>
> I've been using Pd regularly for 7 years now, so I don't consider 
> myself a complete beginner. I use triggers a lot, and only use fan 
> outs when I think the order of events is not critical. For 7 years 
> I've believed that triggers only worked at "micro" level to sequence 
> events that are on the same "level". Of course now I know that this 
> assumption was completely wrong, and if I had tried harder to 
> understand how events are sequenced at "macro" (whole tree) level this 
> would have been obvious.
>
> Honestly I think that this particular problem should be explained much 
> more clearly in the manual, in the depthfirst example file, and 
> perhaps in the trigger help file. I wonder how many people in the 
> pd-list would make the same mistake.
>
> Anyway, than you again for your enlightening responses.
>
> Pierre.
>
> 2015-06-04 8:11 GMT+02:00 Chris McCormick <chris at mccormick.cx 
> <mailto:chris at mccormick.cx>>:
>
>     On 04/06/15 06:03, Jonathan Wilkes via Pd-list wrote:
>     > (And fanouts are more obvious than [trigger] objects wired in the
>     wrong order, and especially where recursion is involved.)
>
>     I am confused by this assertion. Can you explain like I am five?
>
>     Probably my failing but I am unable to imagine a situation in which
>     "fanouts are more obvious than [trigger]" and I don't understand the
>     qualifier "especially where recursion is involved". How do you define
>     "obvious" as used here?
>
>     Last night I spent several hours tracking down a bug that turned
>     out to
>     be because I had used a fan-out instead of a trigger. I am not
>     100% sure
>     if this backs up your point or refutes it but either way it sucked. :)
>
>     I think I will continue to try and make myself use trigger objects
>     instead of fan-outs to avoid that type of bug again.
>
>     Cheers,
>
>     Chris.
>
>     --
>     http://mccormick.cx/
>
>     _______________________________________________
>     Pd-list at lists.iem.at <mailto:Pd-list at lists.iem.at> mailing list
>     UNSUBSCRIBE and account-management ->
>     http://lists.puredata.info/listinfo/pd-list
>
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20150604/a9289655/attachment.html>


More information about the Pd-list mailing list