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

SCORM activities no longer seem to commit the results.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.4
    • Fix Version/s: 2.4
    • Component/s: SCORM
    • Labels:
    • Testing Instructions:
      Hide

      Turn jscache on
      enter SCORM package.
      view source of page to find direct link to cached request.js file - looks like this:
      /lib/javascript.php/1353655141/mod/scorm/request.js

      open file directly in browser and make sure JS exists in the cached file.

      • before this patch in master the following text is shown in the cached file:
        Parse error: Missing operand in file '[inline]' on line 1
      Show
      Turn jscache on enter SCORM package. view source of page to find direct link to cached request.js file - looks like this: /lib/javascript.php/1353655141/mod/scorm/request.js open file directly in browser and make sure JS exists in the cached file. before this patch in master the following text is shown in the cached file: Parse error: Missing operand in file ' [inline] ' on line 1
    • Affected Branches:
      MOODLE_24_STABLE
    • Fixed Branches:
      MOODLE_24_STABLE
    • Pull Master Branch:
      master_MDL-36772

      Description

      All of the SCORM packages that I have tried no longer seem to finish and check off as done.
      I had a talk to Ankit and he directed me to the API debug section.
      It seems that none of the information is being commited to moodle anymore.
      I tested this on 2.3 and that seems to be working.

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            ankit_frenz Ankit Agarwal added a comment -

            Not sure what exactly is going wrong. This are the following things that we noted:-

            1. Manually calling apis from the live debug window doesnt work , I keep getting "Unable to find an API adapter"
            2. Using the same pacakge in 2.3/moodle master. There are LmsCommit calls in 2.3 as expected after the setvalues calls. But I donot see any such calls in master. There is only setvalue calls.

            Thanks

            Show
            ankit_frenz Ankit Agarwal added a comment - Not sure what exactly is going wrong. This are the following things that we noted:- Manually calling apis from the live debug window doesnt work , I keep getting "Unable to find an API adapter" Using the same pacakge in 2.3/moodle master. There are LmsCommit calls in 2.3 as expected after the setvalues calls. But I donot see any such calls in master. There is only setvalue calls. Thanks
            Hide
            salvetore Michael de Raadt added a comment -

            Hi, Dan.

            It would be great if you could help with this issue.

            Show
            salvetore Michael de Raadt added a comment - Hi, Dan. It would be great if you could help with this issue.
            Hide
            salvetore Michael de Raadt added a comment -

            I've asked Ankit to have a look at this also, in case Dan is away.

            Show
            salvetore Michael de Raadt added a comment - I've asked Ankit to have a look at this also, in case Dan is away.
            Hide
            ankit_frenz Ankit Agarwal added a comment - - edited

            There is a Js error when finishing an attempt, which seems to causing this issue
            Also it seems fine to me on stable master

            Timestamp: 23/11/12 14:39:30
            Error: ReferenceError: NewHttpReq is not defined
            Source File: http://ankit.moodle.local/int/master/moodle/mod/scorm/loaddatamodel.php?a=5&scoid=19&currentorg=&attempt=1
            Line: 609

            Show
            ankit_frenz Ankit Agarwal added a comment - - edited There is a Js error when finishing an attempt, which seems to causing this issue Also it seems fine to me on stable master Timestamp: 23/11/12 14:39:30 Error: ReferenceError: NewHttpReq is not defined Source File: http://ankit.moodle.local/int/master/moodle/mod/scorm/loaddatamodel.php?a=5&scoid=19&currentorg=&attempt=1 Line: 609
            Hide
            danmarsden Dan Marsden added a comment -

            yeah - request.js is being screwed - has this content when cached:

            Parse error: Missing operand in file '[inline]' on line 1

            instead of real request.js file.

            Show
            danmarsden Dan Marsden added a comment - yeah - request.js is being screwed - has this content when cached: Parse error: Missing operand in file ' [inline] ' on line 1 instead of real request.js file.
            Hide
            danmarsden Dan Marsden added a comment -

            ah - request.js has <!-- as the first line of the file - which causes the jscache thing to have a hissy fit.

            Show
            danmarsden Dan Marsden added a comment - ah - request.js has <!-- as the first line of the file - which causes the jscache thing to have a hissy fit.
            Hide
            danmarsden Dan Marsden added a comment -

            btw - I'm keen to consolidate some of the js in SCORM at some point - beta release isn't the time for this though.

            Show
            danmarsden Dan Marsden added a comment - btw - I'm keen to consolidate some of the js in SCORM at some point - beta release isn't the time for this though.
            Hide
            ankit_frenz Ankit Agarwal added a comment -

            This one was tricky to track!
            Looks good. +1 for integration

            Show
            ankit_frenz Ankit Agarwal added a comment - This one was tricky to track! Looks good. +1 for integration
            Hide
            samhemelryk Sam Hemelryk added a comment -

            Thanks Dan, this has been integrated now.

            Show
            samhemelryk Sam Hemelryk added a comment - Thanks Dan, this has been integrated now.
            Hide
            samhemelryk Sam Hemelryk added a comment -

            Marking testing passed, it will in fact be tested by MDLQA-4792 and MDLQA-4687.

            Many thanks
            Sam

            Show
            samhemelryk Sam Hemelryk added a comment - Marking testing passed, it will in fact be tested by MDLQA-4792 and MDLQA-4687 . Many thanks Sam
            Hide
            rajeshtaneja Rajesh Taneja added a comment - - edited

            Hello Sam,

            I am getting following notice while uploading attached scrom package (SCORMContentPackageExamples.zip)

            Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: Invalid argument supplied for foreach() in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: array_keys() expects parameter 1 to be array, null given in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 1.1927 95974400 6. array_keys() /var/www/im/mod/scorm/locallib.php:1571 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1572 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined variable: usertracks in /var/www/im/mod/scorm/locallib.php on line 1500 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/locallib.php on line 1765 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/locallib.php on line 1778 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 

            and

            Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 272 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: Invalid argument supplied for foreach() in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: array_keys() expects parameter 1 to be array, null given in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 0.8417 91408808 4. array_keys() /var/www/im/mod/scorm/locallib.php:1571 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1572 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined variable: usertracks in /var/www/im/mod/scorm/locallib.php on line 1500 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 Warning: Invalid argument supplied for foreach() in /var/www/im/mod/scorm/locallib.php on line 1859 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8418 91407000 2. scorm_get_adlnav_json() /var/www/im/mod/scorm/player.php:273 0.8418 91407904 3. scorm_get_adlnav_json() /var/www/im/mod/scorm/locallib.php:1860 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 279 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 

            In STABLE_23 I get following error on filepicker: "Incorrect file package - missing imsmanifest.xml or AICC structure" and it doesn't let me create scrom package.

            Show
            rajeshtaneja Rajesh Taneja added a comment - - edited Hello Sam, I am getting following notice while uploading attached scrom package (SCORMContentPackageExamples.zip) Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: Invalid argument supplied for foreach() in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: array_keys() expects parameter 1 to be array, null given in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 1.1927 95974400 6. array_keys() /var/www/im/mod/scorm/locallib.php:1571 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1572 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 1.1443 95972256 5. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined variable: usertracks in /var/www/im/mod/scorm/locallib.php on line 1500 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 1.1437 95971648 4. scorm_get_toc_object() /var/www/im/mod/scorm/locallib.php:1763 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/locallib.php on line 1765 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/locallib.php on line 1778 Call Stack: 0.0003 746960 1. {main}() /var/www/im/mod/scorm/view.php:0 1.1418 95731248 2. scorm_view_display() /var/www/im/mod/scorm/view.php:157 1.1435 95970672 3. scorm_get_toc() /var/www/im/mod/scorm/locallib.php:883 and Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 272 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: Invalid argument supplied for foreach() in /var/www/im/mod/scorm/locallib.php on line 1544 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Warning: array_keys() expects parameter 1 to be array, null given in /var/www/im/mod/scorm/locallib.php on line 1571 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 0.8417 91408808 4. array_keys() /var/www/im/mod/scorm/locallib.php:1571 Notice: Undefined offset: 0 in /var/www/im/mod/scorm/locallib.php on line 1572 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 0.8415 91406664 3. scorm_get_toc_get_parent_child() /var/www/im/mod/scorm/locallib.php:1493 Notice: Undefined variable: usertracks in /var/www/im/mod/scorm/locallib.php on line 1500 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8411 91405896 2. scorm_get_toc_object() /var/www/im/mod/scorm/player.php:272 Warning: Invalid argument supplied for foreach() in /var/www/im/mod/scorm/locallib.php on line 1859 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 0.8418 91407000 2. scorm_get_adlnav_json() /var/www/im/mod/scorm/player.php:273 0.8418 91407904 3. scorm_get_adlnav_json() /var/www/im/mod/scorm/locallib.php:1860 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 279 Call Stack: 0.0009 814568 1. {main}() /var/www/im/mod/scorm/player.php:0 In STABLE_23 I get following error on filepicker: "Incorrect file package - missing imsmanifest.xml or AICC structure" and it doesn't let me create scrom package.
            Hide
            rajeshtaneja Rajesh Taneja added a comment -

            Tried 211.facts.SCO - Multiscoes .zip package and it go back to the page where I left SCROM (Which is correct).
            Although while going through the SCROM activity it's not checking activity topic on left (green arrow on left is not ticked while going on next page). Green tick is visible if I go back to SCROM activity.

            Show
            rajeshtaneja Rajesh Taneja added a comment - Tried 211.facts.SCO - Multiscoes .zip package and it go back to the page where I left SCROM (Which is correct). Although while going through the SCROM activity it's not checking activity topic on left (green arrow on left is not ticked while going on next page). Green tick is visible if I go back to SCROM activity.
            Hide
            danmarsden Dan Marsden added a comment -

            Rajesh - that zip isn't a SCORM package. - it's a normal zip file.

            if the validation stuff isn't picking it up and throwing an error to say it's not a real SCORM file in master then that's a separate bug unrelated to this issue but it sounds familiar and there might be fix around for it somewhere in review. (I'm away from my machine at the moment.)

            I've seen those js notices before - it's just a reflection of the crappy SCORM js - feel free to log a bug for those and fix them

            Show
            danmarsden Dan Marsden added a comment - Rajesh - that zip isn't a SCORM package. - it's a normal zip file. if the validation stuff isn't picking it up and throwing an error to say it's not a real SCORM file in master then that's a separate bug unrelated to this issue but it sounds familiar and there might be fix around for it somewhere in review. (I'm away from my machine at the moment.) I've seen those js notices before - it's just a reflection of the crappy SCORM js - feel free to log a bug for those and fix them
            Hide
            danmarsden Dan Marsden added a comment -

            Green tick stuff is possibly related to the way the SCORM package is authored - I'd need a lot more info (debug log etc) but this sounds like general SCORM stuff that I'd only bother to look at if it was reported by a real user (not a developer) - when exiting a SCORM it triggers various things that don't necessarily happen when navigating through a SCORM.

            Show
            danmarsden Dan Marsden added a comment - Green tick stuff is possibly related to the way the SCORM package is authored - I'd need a lot more info (debug log etc) but this sounds like general SCORM stuff that I'd only bother to look at if it was reported by a real user (not a developer) - when exiting a SCORM it triggers various things that don't necessarily happen when navigating through a SCORM.
            Hide
            danmarsden Dan Marsden added a comment -

            "js notices" - doh, those ones are the php ones that occur when an invalid package has been added and the validation hasn't picked up a problem. Feel free to create a new bug if validation is no longer picking up invalid packages correctly.

            Show
            danmarsden Dan Marsden added a comment - "js notices" - doh, those ones are the php ones that occur when an invalid package has been added and the validation hasn't picked up a problem. Feel free to create a new bug if validation is no longer picking up invalid packages correctly.
            Hide
            rajeshtaneja Rajesh Taneja added a comment -

            Thanks Dan,

            I just tested one more package "customQuiz - Trackdata.zip" (Which Ankit gave me) and going back to that package gives following error msg

            Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 143  Call Stack:     0.0005     814720   1. {main}() /var/www/im/mod/scorm/player.php:0   Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 154  Call Stack:     0.0005     814720   1. {main}() /var/www/im/mod/scorm/player.php:0   Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 157  Call Stack:     0.0005     814720   1. {main}() /var/www/im/mod/scorm/player.php:0   Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 158  Call Stack:     0.0005     814720   1. {main}() /var/www/im/mod/scorm/player.php:0   Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 168  Call Stack:     0.0005     814720   1. {main}() /var/www/im/mod/scorm/player.php:0  

            Probably other issues and not stopping this one to close, as it works fine on one package (211.facts.SCO)

            Show
            rajeshtaneja Rajesh Taneja added a comment - Thanks Dan, I just tested one more package "customQuiz - Trackdata.zip" (Which Ankit gave me) and going back to that package gives following error msg Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 143 Call Stack: 0.0005 814720 1. {main}() /var/www/im/mod/scorm/player.php:0 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 154 Call Stack: 0.0005 814720 1. {main}() /var/www/im/mod/scorm/player.php:0 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 157 Call Stack: 0.0005 814720 1. {main}() /var/www/im/mod/scorm/player.php:0 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 158 Call Stack: 0.0005 814720 1. {main}() /var/www/im/mod/scorm/player.php:0 Notice: Trying to get property of non-object in /var/www/im/mod/scorm/player.php on line 168 Call Stack: 0.0005 814720 1. {main}() /var/www/im/mod/scorm/player.php:0 Probably other issues and not stopping this one to close, as it works fine on one package (211.facts.SCO)
            Hide
            ankit_frenz Ankit Agarwal added a comment -
            1. I dug a little deeper. The problem happens when you attempt the package, exit the activity after finishing both question but donot click "finish". And than restart the attempt.
            2. There is no error when you finish attempt in the middle of the pack and restart it later.
            3. The error is basically since $result->sco is returned as an array containing a sco object where as the code expects it do be the sco object itself.
            4. Dump of $result without error case:-

              stdClass Object
              (
                  [toc] => <div id="scorm_layout">
              <div id="scorm_toc">
              <div id="scorm_tree">
              <ul>
              	<li>
              <a title="a=7&scoid=23&currentorg=ORG-D0F45010CE879ED4C2A2CFD700E3F8F4&attempt=1"><img src="http://ankit.moodle.local/int/master/moodle/theme/image.php/standard/scorm/1353901637/incomplete" alt="Incomplete" title="Incomplete" />&nbsp;Start Quiz&nbsp;</a>	</li>
              </ul>
              </div></div></div>
              <div id="scorm_navpanel"></div>
               
                  [toctitle] => Flash Custom (Single SCO)
                  [sco] => stdClass Object
                      (
                          [id] => 23
                          [scorm] => 7
                          [manifest] => MANIFEST-3A3A393295D01FA6530767F976AF706A
                          [organization] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4
                          [parent] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4
                          [identifier] => ITEM-0B4EA308CA525F05ACA9283381611BD9
                          [launch] => test.html
                          [scormtype] => sco
                          [title] => Start Quiz
                          [isvisible] => true
                          [parameters] => 
                          [maxtimeallowed] => 0000:30:00:00
                          [timelimitaction] => continue,no message
                          [masteryscore] => 80
                      )
               
                  [prerequisites] => 1
                  [incomplete] => 1
                  [attemptleft] => 1
              )

            5. Dump of $result during the error:-

              stdClass Object
              (
                  [toc] => <div id="scorm_layout">
              <div id="scorm_toc">
              <div id="scorm_tree">
              <ul>
              	<li>
              <a title="a=6&scoid=21&currentorg=ORG-D0F45010CE879ED4C2A2CFD700E3F8F4&attempt=2"><img src="http://ankit.moodle.local/int/master/moodle/theme/image.php/standard/scorm/1353901637/failed" alt="Failed" title="Failed" />&nbsp;Start Quiz&nbsp;(Score:&nbsp;50)</a>	</li>
              </ul>
              </div></div></div>
              <div id="scorm_navpanel"></div>
               
                  [toctitle] => Flash Custom (Single SCO)
                  [sco] => Array
                      (
                          [0] => stdClass Object
                              (
                                  [id] => 21
                                  [scorm] => 6
                                  [manifest] => MANIFEST-3A3A393295D01FA6530767F976AF706A
                                  [organization] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4
                                  [parent] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4
                                  [identifier] => ITEM-0B4EA308CA525F05ACA9283381611BD9
                                  [launch] => test.html
                                  [scormtype] => sco
                                  [title] => Start Quiz
                                  [isvisible] => 1
                                  [parameters] => 
                                  [maxtimeallowed] => 0000:30:00:00
                                  [timelimitaction] => continue,no message
                                  [masteryscore] => 80
                                  [prereq] => 1
                                  [statusicon] => <img src="http://ankit.moodle.local/int/master/moodle/theme/image.php/standard/scorm/1353901637/failed" alt="Failed" title="Failed" />
                                  [url] => a=6&scoid=21&currentorg=ORG-D0F45010CE879ED4C2A2CFD700E3F8F4&attempt=2
                                  [incomplete] => 
                              )
               
                      )
               
                  [prerequisites] => 1
                  [incomplete] => 
                  [attemptleft] => 1
              )

            6. As pointed out earlier this doesnt seem to have to do anything with the issue in hand, this is a whole different context.

            Thanks

            Show
            ankit_frenz Ankit Agarwal added a comment - I dug a little deeper. The problem happens when you attempt the package, exit the activity after finishing both question but donot click "finish". And than restart the attempt. There is no error when you finish attempt in the middle of the pack and restart it later. The error is basically since $result->sco is returned as an array containing a sco object where as the code expects it do be the sco object itself. Dump of $result without error case:- stdClass Object ( [toc] => <div id="scorm_layout"> <div id="scorm_toc"> <div id="scorm_tree"> <ul> <li> <a title="a=7&scoid=23&currentorg=ORG-D0F45010CE879ED4C2A2CFD700E3F8F4&attempt=1"><img src="http://ankit.moodle.local/int/master/moodle/theme/image.php/standard/scorm/1353901637/incomplete" alt="Incomplete" title="Incomplete" />&nbsp;Start Quiz&nbsp;</a> </li> </ul> </div></div></div> <div id="scorm_navpanel"></div>   [toctitle] => Flash Custom (Single SCO) [sco] => stdClass Object ( [id] => 23 [scorm] => 7 [manifest] => MANIFEST-3A3A393295D01FA6530767F976AF706A [organization] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4 [parent] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4 [identifier] => ITEM-0B4EA308CA525F05ACA9283381611BD9 [launch] => test.html [scormtype] => sco [title] => Start Quiz [isvisible] => true [parameters] => [maxtimeallowed] => 0000:30:00:00 [timelimitaction] => continue,no message [masteryscore] => 80 )   [prerequisites] => 1 [incomplete] => 1 [attemptleft] => 1 ) Dump of $result during the error:- stdClass Object ( [toc] => <div id="scorm_layout"> <div id="scorm_toc"> <div id="scorm_tree"> <ul> <li> <a title="a=6&scoid=21&currentorg=ORG-D0F45010CE879ED4C2A2CFD700E3F8F4&attempt=2"><img src="http://ankit.moodle.local/int/master/moodle/theme/image.php/standard/scorm/1353901637/failed" alt="Failed" title="Failed" />&nbsp;Start Quiz&nbsp;(Score:&nbsp;50)</a> </li> </ul> </div></div></div> <div id="scorm_navpanel"></div>   [toctitle] => Flash Custom (Single SCO) [sco] => Array ( [0] => stdClass Object ( [id] => 21 [scorm] => 6 [manifest] => MANIFEST-3A3A393295D01FA6530767F976AF706A [organization] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4 [parent] => ORG-D0F45010CE879ED4C2A2CFD700E3F8F4 [identifier] => ITEM-0B4EA308CA525F05ACA9283381611BD9 [launch] => test.html [scormtype] => sco [title] => Start Quiz [isvisible] => 1 [parameters] => [maxtimeallowed] => 0000:30:00:00 [timelimitaction] => continue,no message [masteryscore] => 80 [prereq] => 1 [statusicon] => <img src="http://ankit.moodle.local/int/master/moodle/theme/image.php/standard/scorm/1353901637/failed" alt="Failed" title="Failed" /> [url] => a=6&scoid=21&currentorg=ORG-D0F45010CE879ED4C2A2CFD700E3F8F4&attempt=2 [incomplete] => )   )   [prerequisites] => 1 [incomplete] => [attemptleft] => 1 ) As pointed out earlier this doesnt seem to have to do anything with the issue in hand, this is a whole different context. Thanks
            Hide
            rajeshtaneja Rajesh Taneja added a comment -

            Thanks Ankit,

            I have passed linked QA test. Can you please open an issue as you know exactly what is going on there.

            Show
            rajeshtaneja Rajesh Taneja added a comment - Thanks Ankit, I have passed linked QA test. Can you please open an issue as you know exactly what is going on there.
            Hide
            tsala Helen Foster added a comment -

            Removing mdlqa tag as as linked QA test has been passed.

            Show
            tsala Helen Foster added a comment - Removing mdlqa tag as as linked QA test has been passed.
            Hide
            stronk7 Eloy Lafuente (stronk7) added a comment -

            Y E S !

            Closing as fixed, many thanks!

            Show
            stronk7 Eloy Lafuente (stronk7) added a comment - Y E S ! Closing as fixed, many thanks!

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  3/Dec/12