What is the role of 'Role'?

When adding an event to a person, there’s a field called ‘Role’. My understanding is that ‘Role’ is a description of the person’s involvement in the event. There’s a number of predefined roles, but any text can be entered.

An example: In censuses, which are typically household based, each person have a role, usually ‘housefather’, ‘housewife’, ‘son/daughter/child’, ‘relative’, ‘lodger’, ‘servant’ etc. So I create the census event and add it to each person in the family mentioned in the census source with the according role description.

But what is the role information used for in Gramps?
When I create any report it looks like all events not having Role equal to ‘Primary’ are filtered out ! So the big question - is the only purpose of ‘Role’ to prevent the events appearing in reports?

1 Like

Roles is an subject of the User Guide that needs improvement.

A “Roles, Relationships & Associations” article was started but never progressed far enough to be useful. It is just a “stub” placeholder. If this thread creates a better understanding of Roles, perhaps the article could improved and be linked from the Glossary Terms. (And allow the Gossary entries to be abbreviated.)

The :bookmark_tabs: Gramps Glossary breaks it down into 3 terms:

  • role (in general) : function performed or part played by a person (or other Gramps object) in a particular situation. When objects of Gramps are linked, a Reference is created where the implicit Role disambiguates the relative nature of the reference. For explicitly defined roles, see event role and association role
  • Event Role : The role a Person plays in an Event. The focal Person(s) holds a Primary role in personal Events and the Family holds a Family role in Family events. In Gramps, an Event can be linked to as many participants as desired. Each Person may participate in different roles but more than one Person might play the same role. The Event Role captures this and can be changed in the Event Reference Editor. Some common Roles are pre-defined but the user can add other custom Roles by just typing in the appropriate new label into the selector combo box.
    Pre-defined Types of Event Role: Aide, Bride, Celebrant, Clergy, Family, Godparent, Groom, Informant, Primary, Witness, Unknown, custom
  • Association Role : (sec. obj.) - The roles in Associations are to explicitly define the how one person relates to another.
    Association roles are used when the relationship falls outside the implicit roles of a family relationship or the explicit roles in shared events. These custom roles convey relationships that might not readily apparent… such as a penpal or the eponymous person honored by a namesake. Association roles may also be used as placeholder when the actual genetic connection has not yet been discovered.
    Association roles are created and edited with the Person Reference Editor, which includes no pre-defined roles. This feature starts with a blank list of custom types) and the default “Godfather” role is only shown as a hint.

clarification: Primary for Person Events and Family for Family Events are the 2 roles that are almost always recognized by reports.

One purpose for which I leverage the Role is for exclusionary purposes. For disproven events (such as when a Baptism date has propagated as a Birth date in many reference books and databases), I will set the Role as Disproven.

This allows me to store the research about why I believe it to be misinformation.

However, export of Events with non-standard Roles might drop the Role distinction… and propagate the mythical event.

Roles are important for Shared events. When the same event record is shared with other people who had a Role in the event. The main person is Primary. Many reports and tools are designed to only look at the Primary person.

A person’s Baptism/Christening would be Primary for the person, but others sharing the event could be Godfather, Godmother, Officiant.

Sharing a families’ Marriage record could be the Officiant, members of the wedding party or Witnesses to the signed certificate.

In a Census record the Primary would be Head of Family or Household and the shared Roles would be the their relationship to that Primary/Head.

The big events for a person; Birth, Death, Burial need to be Primary. The same goes for the Family’s main events Marriage and Divorce need to have the role Family.

The role is demoted to “uknown” in the shared reference.

Whether you drag’n’drop or use the Event Selector dialog to share, it is always necessary to choose the correct role.

I looked into the code of “Detailed Descendant Report”.
It’s using a method named person.get_primary_event_ref_list.

However, there’s also a person.get_event_ref_list method, so I changed one line in the report code, and now I get the expected output.

1 Like

You just need to set up a system to make the same changes after installing a Gramps upgrade.

Did a GitHub repository search for that person.get_primary_event_ref_list method in the addons. And another search in the core.

Which report did you hack?

Yes, the best would of course be to change the report, so you can choose to include all events or only those with primary role.
I guess that would require a change request, but I don’t know how or whre to ask for that.

./plugins/textreport/detdescendantreport.py

The change looks like this:

        if self.inc_events:
#           for event_ref in person.get_primary_event_ref_list():
            for event_ref in person.get_event_ref_list():
                if first:
2 Likes

Thanks. Added links.

Referenced the line number of that Report module on 5.2 maintenance branch on GitHub. This allows others to find the exact spot that you tweaked.

Added links in your original posting so that the method description can be found in the Developer docs. (The 1st link is an example of search all the develop docs for a method name … the search found 4 instances. The 2nd method links to the result General module docs rather than the Utilities module.)

We don’t mention the documentation resources often enough.

MantisBT59x52, 25%
The Contact page on the Wiki has a Requesting enhancements subsection. We use the MantisBT issue tracker. (Switching to GitHub Issues is currently being discussed on the Developer mailling list.)

1 Like

Created ID = 0013596 in MantisBT

0013596: Detailed Descendant Report only lists events with role = Primary

Regards
Claus

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.