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

Users enrolled in a large number of courses experience browser unresponsiveness when using IE8 and 9

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Major Major
    • None
    • 2.3.2
    • Navigation, Performance
    • MOODLE_23_STABLE

      I've been following some of the different JavaScript performance issues including http://tracker.moodle.org/browse/MDL-34328 and couldn't find one specifically for the issue I'm having.

      When users are enrolled in lots of courses some JavaScript that works on the My Courses section of the navigation block takes an awful long time to do what it needs to do and causes the browser to become unresponsive. Eventually the "Stop running this script" message box appears. I've seen this behaviour in both IE8 and IE9.

      I've done some rudimentary profiling of the code in blocks/navigation/yui/navigation/navigation.js and found that TREE.initializer seems to be causing the slow down, specifically this for loop:

      // Establish each expandable branch as a tree branch.
      for (var i in expansions) {
          new BRANCH({
              tree:this,
              branchobj:expansions[i],
              overrides : { 
              expandable : true,
                  children : [], 
                  haschildren : true
              }   
          }).wire();
          M.block_navigation.expandablebranchcount++;
      }
      

      I have a user enrolled in about 950 courses where this section of JavaScript code running on IE8 on a reasonably powerful machine can take 38 seconds to run. Even for a user enrolled in a more sensible number of courses like 25, this section of code can take almost a whole second to run which would be starting to have a noticeable impact on the user experience. Obviously the navigation block appears in lots of places throughout Moodle so as a result the slow down can have a big impact on a user's overall Moodle experience.

      I've also seen a similar level of unresponsiveness experienced by users viewing the profile of another user that is enrolled in a large number of courses, probably for a similar reason.

            Unassigned Unassigned
            nmares Nathan Mares
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved:

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