Generate reports including photos?

I don’t know why it takes so long, but my suspicion is that it is related to all of the searches required to build the References section of the pages as the References section includes a list of citations, people and events. It may also be in part because I do not generate family or event pages (my hosting company places limits on both disc space and inodes; if event and family pages are generated, it significantly exceeds the inode limit).

I haven’t attempted to understand the database structure, but I suspect that for media objects attached to citations, it is only easy to retrieve the source and/or citation(s) (Dynamic Web reports only list sources in the References section, although it lists a source for each citation, so it isn’t unusual to have a list that has the same source repeated multiple times; I don’t know whether that is because of the queries available or because there are no citation pages to link to).

If the citation is attached to an event, that means that at a minimum two more queries are required, one to retrieve the event(s) associated with the citation(s) and one to retrieve the people associated with the event(s). (I think the final query may be skipped if event pages are generated. As an experiment, I will have to see if the time goes down if I generate event pages, but that wouldn’t help with the public website I maintain.) Since more than two-thirds of the media objects in my database are attached to citations and the census pages are attached to anywhere from one to ten citations, there may be a lot of queries to generate the references. It would be interesting to see if indexes could be auto-generated that would make those queries more efficient (most of my database experience was with Oracle and that has been over 15 years, so I don’t know if that even makes sense in SQLite).

Allen

@alcofribas for some more detail, if 2 people share an event you would see the following.

  • person 1
    • details
    • events
      • event1
        • details
        • photoA
  • person 2
    • details
      • events
        • event 1
          • details
          • photoA (same as above)

Seems like an easy change. You could put in a PR at GitHub for it.

PR submitted to fix issue. I am not a github expert, but I think I did this PR correctly. Waiting for review and merge.

1 Like

The PR will handle missing images for events. However it doesn’t handle missing media for citations without date or page. I did some experimenting and it seems that citations without date or page don’t appear at all. I’m not sure what is causing those citations to not show up.

Good question! I perfectly understand it.

Honestly I’m quite new to genealogy, I do not know what to (seriously) answer.

Excepting wedding and witness, what events could be shared between people?

The bibliography is generated (by core gramps) before the report code is executed. That biblio does not include the citation if there is nothing defined in the citation in the date or page/volume fields.

The report then uses the information in the biblio to generate the report. As example, look at the Person view Citation tab. If there is an event that has a citation without date or page/volume, the citation is not included in the Person view Citation tab (see the “<No Citation>” in the furthest back window).

So this cannot be fixed in the report (other than noting this requirement). It is in core gramps, which is beyond me.

1 Like

I started digging into the source some more and the constructor for Bibliography allows one to specify the “mode”. If one passes in MODE_ALL, then I believe these empty citations will appear. Line 203 of detdescendantreporti.py specifies MODE_DATE|MODE_PAGE. Changing this to MODE_ALL shows all citations.

1 Like

PR is in as Include all citations in the bibliography by jpschewe · Pull Request #545 · gramps-project/addons-source · GitHub

2 Likes

I have a similar observation: when I produced a detailed ancestor (text) report including photos, the only photo I got was of the selected person. I would like it to include all available photos of the ancestors when I tick the option to include photos in the report.

Alan

Other shared events could include Residence, Census, Immigration, …

1 Like

I’m posting this link as it may be of value to others, until the next merge. Check the date of this post compared to the (future) release date.

https://gramps.discourse.group/t/permissive-vs-restrictive-philosophy/2674/4?u=iabarry

Having looked at the .PY referenced immediately above, I see no sign of image/media size for the report. Apparently this is determined elsewhere.

My personal preferences for images would be that the image is shown followed immediately by the image NOTE. These often list the folks in the photo, discuss location, dates, etc.

The Reports → WebPage → Narrated Site does this nicely. I’m disappointed this doesn’t work the same in Report → Text → Detailed with images.

I wonder if the Text report image size is limited by the table? If it were 2 columns rather than 3, would the image be larger? Possibly there are pseudo-thumbnails with a size spec somewhere else.