I’m a little late because 6.0 has been released, but these changes have introduced a bug in my SuperTool scripts and custom filters.
SuperTool allows to use custom filters in scripts. Under the hood it uses the match function of the filter, and this has been changed to use apply_to_one . However, it seems apply_to_one doesn’t make sure that requestprepare has been called on the underlying rules. As a result, it fails (I was using IsAncestorOf and it complained about selected_handles not existing).
I am not sure where the fix should be (Gramps or SuperTool), that’s why I haven’t filed a proper bug report. My instinct as a developer is that since apply_to_one relies on the rules being prepared, it should ensure they actually are, but maybe it’s expected that developers using filters initialize them (but then I couldn’t find an obvious way of doing so, like a requestruleprepare function in the GenericFilter class or something like that).
As an experiment, I added a call to requestprepare on rules in apply_to_one. I was of course hit with “The filter definition contains a loop.” because my script called the filter more than 20 times… when commenting that, everything worked ok. It’s probably the worst way to fix it but it did confirm the source of the problem.
I can file a bug report if you want, just tell me where.