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

Atto autosave causes JS error in assignment grading interface

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.1, 3.2
    • Fix Version/s: 3.1.1
    • Component/s: Assignment
    • Labels:
    • Testing Instructions:
      Hide

      Prerequisites:
      You must have a course with at least 2 enrolled students and an assignment.

      Test Steps

      1. Set Atto autosave frequency to 10 seconds. Site admin > Plugins > Text editors > Atto HTML Editor > Atto toolbar settings (bottom of page)
      2. Go to an assignment with participants.
      3. Access the grading interface and open your browser console.
      4. Type some content in the Feedback atto editor and wait for the draft to be saved. After about 10 seconds, you should see a notification to the bottom right of the editor saying 'Draft saved'.
      5. As soon as you see the notification message, change to the next user using the arrows at the top, and click the 'Save and continue' button on the dialog quickly. Note: You must do this before the 'Draft saved' notification has closed.
      6. Confirm that you don't see any error output in the console.
      7. Try this a few times to make sure.
      Show
      Prerequisites: You must have a course with at least 2 enrolled students and an assignment. Test Steps Set Atto autosave frequency to 10 seconds. Site admin > Plugins > Text editors > Atto HTML Editor > Atto toolbar settings (bottom of page) Go to an assignment with participants. Access the grading interface and open your browser console. Type some content in the Feedback atto editor and wait for the draft to be saved. After about 10 seconds, you should see a notification to the bottom right of the editor saying 'Draft saved'. As soon as you see the notification message, change to the next user using the arrows at the top, and click the 'Save and continue' button on the dialog quickly. Note: You must do this before the 'Draft saved' notification has closed. Confirm that you don't see any error output in the console. Try this a few times to make sure.
    • Affected Branches:
      MOODLE_31_STABLE, MOODLE_32_STABLE
    • Fixed Branches:
      MOODLE_31_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-54795_master
    • Sprint:
      3.2 Sprint 2

      Description

      1. Go to an assignment with participants
      2. Access the grading interface and open your console
      3. Type some content in the Feedback atto editor and wait for the draft to be saved
      4. Reload the page
      5. Your draft should be restored, as soon as it is switch to another user

      Expected

      • There are no Javascript errors

      Actual

      • After about 60 seconds, you will notice a Javascript error
        • Uncaught TypeError: Cannot set property '_transition' of null

      According to my quick analysis it is due to the code trying to hide the notification (Draft restored, draft saved, etc...) but it does not exist any more.

      It may be easier to replicate this using Chrome

      Steps to replicate in Chrome

      Note: I'd recommend setting Atto autosave frequency to 10 seconds first.

      1. Go to an assignment with participants
      2. Access the grading interface and open your console.
      3. Type some content in the Feedback atto editor and wait for the draft to be saved. You'll see a notification to the bottom left saying 'Draft saved'.
      4. As soon as you see the notification message, change to the next user and you should see the console error within about 5 seconds.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                11/Jul/16