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

Exception raised when processing portfolio exports via cron

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • None
    • 2.4.7, 2.5.3
    • Portfolio
    • MOODLE_24_STABLE, MOODLE_25_STABLE
    • MDL-42802-master
    • Hide
      1. Set up the portfolio Flickr
      2. Set portfolio_moderate_filesize_threshold and portfolio_high_filesize_threshold to 10kb
      3. Create a forum post with an image (more than 10kb)
      4. Export the image to Flickr portfolio and choose Don't wait on the export page
      5. Run the Cron and make sure the file was exported successfully
      1. Back to the forum post, export the image again
      2. Again, choose "Don't wait"
      3. Navigate to Home / My profile settings / Portfolios / Transfer logs and cancel the export
      4. Run the cron
      5. Make sure you don't see an nasty exception, but you see "Skipping unknown portfolio export with ID X".
      Show
      Set up the portfolio Flickr Set portfolio_moderate_filesize_threshold and portfolio_high_filesize_threshold to 10kb Create a forum post with an image (more than 10kb) Export the image to Flickr portfolio and choose Don't wait on the export page Run the Cron and make sure the file was exported successfully Back to the forum post, export the image again Again, choose "Don't wait" Navigate to Home / My profile settings / Portfolios / Transfer logs and cancel the export Run the cron Make sure you don't see an nasty exception, but you see "Skipping unknown portfolio export with ID X".

      I'm still working on reproducing this bug manually, but when a portfolio has been set to be exporter during cron, and it doesn't exist (I suppose because the user deleted it), an exception is raised and the cron stops.

      ++ Handler function of component moodle: s:22:"portfolio_handle_event"; threw exception :Invalid export id. Maybe it has expired
      * line 944 of /lib/portfoliolib.php: call to portfolio_exporter::rewaken_object()
      * line ? of unknownfile: call to portfolio_handle_event()
      * line 299 of /lib/eventslib.php: call to call_user_func()
      * line 343 of /lib/eventslib.php: call to events_dispatch()
      * line 450 of /lib/eventslib.php: call to events_process_queued_handler()
      * line 340 of /lib/cronlib.php: call to events_cron()
      * line 61 of /admin/cli/cron.php: call to cron_run()
       ++
      * line 366 of /lib/eventslib.php: call to debugging()
      * line 450 of /lib/eventslib.php: call to events_process_queued_handler()
      * line 340 of /lib/cronlib.php: call to events_cron()
      * line 61 of /admin/cli/cron.php: call to cron_run()
      

      This is highlighted by the fact that MDL-42542 has been fixed.

            Unassigned Unassigned
            fred Frédéric Massart
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

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