Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-76481

Download accessibility summary report giving error in PHP8

XMLWordPrintable

    • MOODLE_311_STABLE, MOODLE_400_STABLE, MOODLE_401_STABLE
    • MOODLE_400_STABLE, MOODLE_401_STABLE
    • MDL-76481_401_Brickfield_TCPDF_error
    • MDL-76481_master_Brickfield_TCPDF_error
    • Hide
      1. Register the site with Brickfield on site admin > plugins > accessibility > brickfield registration
        1. Please note that registration requires a unique url, so in the case of registering a localhost site, you can use a random port number to do so. Using a tool like ngrok would also be sufficient.
      2. Navigate to Plugins > Admin tools > Accessibility > Accessibility toolkit settings
      3. Tick Enable analysis requests and save changes
      4. Submit a course for analysis from the course settings > accessibility toolkit
      5. Wait for the analysis to complete or by running the scheduled tasks:
      6. \tool_brickfield\task\process_analysis_requests
      7. \tool_brickfield\task\bulk_process_caches
      8. Navigate to the summary report for the course from course settings > accessibility toolit > summary report
      9. Click 'Download PDF'

       
      Before applying the patch this will generate the error, and after the patch the PDF should download as normal.

      Show
      Register the site with Brickfield on site admin > plugins > accessibility > brickfield registration Please note that registration requires a unique url, so in the case of registering a localhost site, you can use a random port number to do so. Using a tool like ngrok would also be sufficient. Navigate to Plugins > Admin tools > Accessibility > Accessibility toolkit settings Tick Enable analysis requests and save changes Submit a course for analysis from the course settings > accessibility toolkit Wait for the analysis to complete or by running the scheduled tasks: \tool_brickfield\task\process_analysis_requests \tool_brickfield\task\bulk_process_caches Navigate to the summary report for the course from course settings > accessibility toolit > summary report Click 'Download PDF'   Before applying the patch this will generate the error, and after the patch the PDF should download as normal.

      We are experiencing this error since we upgraded to PHP in our system. When we wish to download the analysis report from a course we get the following error:
       

      Exception - array_push(): Argument #1 ($array) must be of type array, null given

       
      Debug info:
      Error code: generalexceptionmessage×Dismiss this notification
      Stack trace: * line 18308 of /lib/tcpdf/tcpdf.php: TypeError thrown

      • line 18308 of /lib/tcpdf/tcpdf.php: call to array_push()
      • line 5901 of /lib/tcpdf/tcpdf.php: call to TCPDF->writeHTML()
      • line 18330 of /lib/tcpdf/tcpdf.php: call to TCPDF->MultiCell()
      • line 273 of /admin/tool/brickfield/classes/output/printable/renderer.php: call to TCPDF->writeHTML()
      • line 227 of /admin/tool/brickfield/classes/local/tool/printable.php: call to tool_brickfield\output\printable\renderer->pdf_renderer()
      • line 131 of /admin/tool/brickfield/index.php: call to tool_brickfield\local\tool\printable->get_output()

            bigmoodle Max Larkin
            A_Deb Amrita Deb Dutta
            Simey Lameze Simey Lameze
            Paul Holden Paul Holden
            Kim Jared Lucas Kim Jared Lucas
            Votes:
            6 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 0 minutes
                0m
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 5 hours, 51 minutes
                5h 51m

                  Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.