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

An empty H5P activity will generate an error

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Minor Minor
    • None
    • 3.11.8
    • H5P
    • MOODLE_311_STABLE

      I found this via our monitoring:

      Error: Uncaught exception 'Error' with message 'Call to a member function get_contextid() on bool' in /var/www/html/mod/h5pactivity/view.php:57
      

      It appears that the H5P activity does not have any files associated to it, which causes the following error.

      It looks like this can happen if the following happens:

      1. Create a H5P activity
      2. In administration disable the content type added to the activity
      3. Use the duplicate, import or another backup and restore function to create a new copy of the activity.

            Unassigned Unassigned
            nmagill Neill Magill
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 hour, 3 minutes
                1h 3m

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