Fork me on GitHub

Looking for options for debugging rules. Would have saved some time discovering typos etc today if I could have switched on debug logging evaluating every condition of a given rule say. Or even had "explain-non-activations". Any tips?


Ok. So it looks like inspect would have helped me. Will also try tracing tomorrow...


Inspect might be more helpful if you’re looking at ordinary sorts of errors like a bad rule etc. Tracing can be useful too but definitely gets into implementation details


If it concerns exceptions running against the branch that is out and in progress for could be helpful too


Thanks :) Was more about straightforward debugging. Just getting started with Clara!


Also - looking at source of load-rules in clara/rules.cljc you can just supply a list of symbols resolving to individual rules, not just namespaces - is that correct? Would love an example of this. Flexibility around how rules are assembled would be great.


I think a call to mk-session like the one at is what you’re talking about, ignoring the :fact-type-fn and :ancestors-fn options