Search Forums
Forums
Kiwitrees on Twitter
    Tags

    kiwitrees 2.0.2, 3.3.0, autocomplete, users, individual resource, spam, logout, family fact, data errors, GEDCOM errors, release, watermark, theme, danish, googlemaps, gender change, library, 500, contacts, tabs, burial, partner, pdf, php 7, blocks, save settings, simpl_research, shared note, ADDR, login failure, event, Georgian, locked out, getClientIp, links, transifex, repo, check, latest version, login upgrade, kiwitrees theme, birth, advent, add, 3.1.1, 5.6, image, BAPM, github, beta, sanity checker, progress, validation, immigration, census assistant, Extra menus, roadmap, icons, slideshow, Search and replace

    Tagged: 

    Topic:   Reports  

    This topic contains 7 replies, has 3 voices, and was last updated by kiwi kiwi 2 years, 7 months ago.

    Viewing 8 posts - 1 through 8 (of 8 total)
    • Author
      Posts
    • #4412
      pab
      pab
      Participant

      139 posts

      Not used reports for ages but just now tried them with 3.0.0 and get errors:
      ERROR 2: sprintf(): Too few arguments
      followed by various lines of details depending on which report selected

      Penguins Are Boss

      Apache 2.4.25; MariaDB 10.1.22; PHP 7.0.18

      http://bootesgowland.info

      #4413
      kiwi
      kiwi
      Keymaster

      1595 posts

      I think that’s a bug in the “Ancestors” report texts. Can you disable just that report [Admin > Modules > Manage modules > Ancestors] and let me know if the error disappears?

      Nigel
      My personal kiwitrees site is www.our-families.info
      #4414
      kiwi
      kiwi
      Keymaster

      1595 posts

      Sorry, ignore first reply. I’m pretty sure I’ve found the problem.

      Try replacing the file /includes/reportheader.php with the version in the attached zip folder.

      Nigel
      My personal kiwitrees site is www.our-families.info
      #4416
      Roy
      Roy
      Participant

      122 posts

      It should be noted that the problem appears to be for the PDF report versions. The HTML output works; at least on the ones that I have tried.

      Roy

      Apache 2.4.27  PHP 7.19 MariaDB 10.2.8

      #4417
      pab
      pab
      Participant

      139 posts

      The problem is still there.
      It only appears for reports: Ancestors, births, cemeteries, deaths, missing data, occupations, related indis, sources, and vital records. And it appears immediately, ie. before selecting whether PDF or HTML

      Ancestors and sources produce mostt errors

      Ancestors

      Penguins Are Boss

      Apache 2.4.25; MariaDB 10.1.22; PHP 7.0.18

      http://bootesgowland.info

      Attachments:
      #4419
      kiwi
      kiwi
      Keymaster

      1595 posts

      OK. Thanks for the feedback. The ‘fix’ I provided was a start, but it missed the real issue, and also introduced a new one, so please delete that and revert to the original file (I can supply a copy of that if you need it).

      The ‘real’ issue was surprisingly in the en_GB.mo translation file.

      Please try the attached version.

      Remember to go to Admin > Site Administration > Clean up data folder and delete the “cache’ folder completely. Then return to and refresh the Reports pages. I’ve tested most of them and they are working OK for me, but it is still possible I missed one.

      Nigel
      My personal kiwitrees site is www.our-families.info
      Attachments:
      #4421
      pab
      pab
      Participant

      139 posts

      Thanks, they all seem OK. What a strange dependency!

      Penguins Are Boss

      Apache 2.4.25; MariaDB 10.1.22; PHP 7.0.18

      http://bootesgowland.info

      #4422
      kiwi
      kiwi
      Keymaster

      1595 posts

      What a strange dependency!

      Actually not so strange once I thought it through carefully.

      In our translations we often embed variables for things like number counts. For example, there is a phrase “Total individuals: xxx” where xxx is a number. The translatable text is therefore WT_I18N::translate(‘Total individuals: %s’, $count_indis) . Here the result of the calculated variable $count_indis is inserted in the text at the position of ‘%s’. Doing it like this ensures any language can work with the same variable even if its position in the sentence needs to change. But it is essential that ALL languages include the ‘%s” variable. In the en_GB file the ‘%s’ variable had been accidentally missed from the translation. Hence the error message “Too few arguments”. It was looking for the variable in the translation and it wan’t there.

      Nigel
      My personal kiwitrees site is www.our-families.info
    Viewing 8 posts - 1 through 8 (of 8 total)

    You must be logged in to reply to this topic.