Expand RuleMethodError
with list of defined rules for given node
#397
Labels
RuleMethodError
with list of defined rules for given node
#397
Currently, when a node is connected to an edge which has a distribution that does not match any of the input argument types for the defined message rules, ReactiveMP will throw a
RuleMethodError
. For example, the modelwill throw:
For new users, this error is difficult to read, interpret and overcome, especially if the user is also new to Julia and is unfamiliar with interpreting stack traces. I propose that we output the list of rules that are defined, for example:
This may help the user specify a model for which inference can be executed successfully.
@bartvanerp already compiled a list in ReactiveMP's documentation: https://reactivebayes.github.io/ReactiveMP.jl/stable/lib/rules/#lib-rules-table. This will save a lot of time; we just need to alter the
RuleMethodError
code inrule.jl
such that it performs a look-up and prints in a user-friendly way.Suggestions during today's RxInfer meeting mentioned a hierarchical printout. I will look into this.
The text was updated successfully, but these errors were encountered: