Possible event filter malfunction?

Hello all,

Gramps 6.0.8, flatpak running on Ubuntu 26.04

I think that I have come across a bug in an event filter - I shall explain further with an example based on the Example tree.

I have built 1 person filter and 2 event filters to show this (see below). The person filter selects 3 persons of the Garner family: Robert W., Lewis Anderson and Robert F. They all 3 have marriage events. You can see this when you run my event filter “Test find events 1” where I filter for events for persons matching a person filter. However, you also see the marriage of Arnold Wójcik and Helen Bernice Garner where Robert F. is a witness (you may additionally filter the result on the event type). As I don’t want this latter event in my results I modify the event filter to include the role value Primary, see/run “Test find events 2”. Now the unwanted marriage event has gone but so has also the marriage event of Lewis Anderson Garner von Zieliński Sr and Luella Jacques Martel. On the other hand, the two marriage events for the other Garner men are still there. How can that be? Has Lewis Anderson Garner not got a Primary role in his own wedding?

My own analysis by investigating more examples in my own tree indicates that the problem relates to family events that are shared with non-Primary participants.

Can anybody reproduce/explain my findings? Is there a workaround for this? Have I done something wrong or is it really a bug?

Here are the filters that I used:

<?xml version="1.0" encoding="utf-8"?>
<filters>
  <object type="Event">
    <filter name="Test find events 1" function="and" comment="Events for selected people, including family events but no role specified">
      <rule class="MatchesPersonFilter" use_regex="False" use_case="False">
        <arg value="Test person selection"/>
        <arg value="1"/>
      </rule>
    </filter>
    <filter name="Test find events 2" function="and" comment="Events for selected people, including family events and role Primary specified">
      <rule class="MatchesPersonFilterRole" use_regex="False" use_case="False">
        <arg value="Test person selection"/>
        <arg value="1"/>
        <arg value="Primary"/>
      </rule>
    </filter>
  </object>
  <object type="Person">
    <filter name="Test person selection" function="or" comment="Select the people for the bug test">
      <rule class="HasIdOf" use_regex="False" use_case="False">
        <arg value="I00106"/>
      </rule>
      <rule class="HasIdOf" use_regex="False" use_case="False">
        <arg value="I00044"/>
      </rule>
      <rule class="HasIdOf" use_regex="False" use_case="False">
        <arg value="I01123"/>
      </rule>
    </filter>
  </object>
</filters>
```

Regards,

mo.eu

1 Like