SCORM 2004 Courses Not Working In Moodle 2.0

SCORM 2004 Courses Not Working In Moodle 2.0

by Joe Flaherty -
Number of replies: 9

Recently we've upgraded to Moodle 2.0.2 from Moodle 1.9 and have been unable to get any of our SCORM 2004 courses to save data. I've been watching the logs through the SCORM Debugging interface, everything seems fine, but upon reentering the course it appears that everything has been reset. I checked the project settings and neither force completed or force new attempt are on. Below is our SCORM log, any help would be greatly appreciated.

The only thing I've noticed is that the log says that the 1.2 API is loaded even though this is 1.3/2004 course (and specified as such in the imsmanifest). When the exact same course was in 1.9 I remember it using 1.3.

Wed, 16 Mar 2011 23:00:47 GMT: Moodle SCORM 1.2 API Loaded, Activity: Test Course, SCO: CourseItem01
Wed, 16 Mar 2011 23:01:08 GMT: Initialize("", "") => 0
Wed, 16 Mar 2011 23:01:08 GMT: GetValue("cmi.completion_status") - unknown => 0
Wed, 16 Mar 2011 23:01:08 GMT: GetValue("cmi.entry") - ab-initio => 0
Wed, 16 Mar 2011 23:01:08 GMT: SetValue("cmi.completion_status", "incomplete") => 0
Wed, 16 Mar 2011 23:01:08 GMT: SetValue("cmi.suspend_data", "") => 0
Wed, 16 Mar 2011 23:01:08 GMT: SetValue("cmi.exit", "suspend") => 0
Wed, 16 Mar 2011 23:01:10 GMT: Commit("", "") => 0
Wed, 16 Mar 2011 23:01:20 GMT: SetValue("cmi.suspend_data", "score=0|examcount=0|section=1|gender=male") => 0
Wed, 16 Mar 2011 23:01:21 GMT: Commit("", "") => 0
Average of ratings: -
In reply to Joe Flaherty

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Joe Flaherty -

As a follow up, I installed a sample course from the golf examples at http://scorm.com/scorm-explained/technical-scorm/golf-examples/ and it also failed to work with the exact same results that I had listed earlier. It still stated that 1.2 API Loaded and the course didn't register any attempts in Moodle.

At this point we've decided to revert back the old version of Moodle we were using. If anyone could possibly help with this it would be great, otherwise we will have to continue using an older version of Moodle.

In reply to Joe Flaherty

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Joe,
in MDL 2.0 the "Moodle SCORM 1.2 API Loaded" statement is printed out regardless the type of API really used: it's a minor bug (MDL-26863), I'm just taking a look at it. It should break just the information of what has been really loaded but not the way the tracking data is stored. It could be nice if you can share your package to give the chance to replicate the issue.

HTH,
Matteo

In reply to Matteo Scaramuccia

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Adam Schuldt -

Hi Matteo,

We've been able to replicate this error, and what's more, though the log reports success when setting standard SCORM vars with the SCORM 2004 commands (such as GetValue and SetValue for the fields cmi.score.raw, cmi.score.min, and cmi.score.max), the score for our package is not stored to the Gradebook. Using the debug tools to set the fields doesn't actually set the field either.

 

SCORM Version Detected: scorm_13

Thu, 17 Mar 2011 16:26:03 GMT: Moodle SCORM 1.2 API Loaded, Activity: debug2, SCO: AS2SCORM2004_item01
Thu, 17 Mar 2011 16:26:28 GMT: Initialize("", "") => 0
Thu, 17 Mar 2011 16:26:28 GMT: SetValue("cmi.completion_status", "incomplete") => 0
Thu, 17 Mar 2011 16:26:28 GMT: SetValue("cmi.score.min", "0") => 0
Thu, 17 Mar 2011 16:26:28 GMT: SetValue("cmi.score.max", "10") => 0
Thu, 17 Mar 2011 16:26:31 GMT: SetValue("cmi.score.raw", "4") => 0
Thu, 17 Mar 2011 16:26:31 GMT: GetValue("cmi.score.raw") - 4 => 0
Thu, 17 Mar 2011 16:26:31 GMT: SetValue("cmi.completion_status", "completed") => 0
Thu, 17 Mar 2011 16:26:32 GMT: Commit("", "") => 0
Thu, 17 Mar 2011 16:26:32 GMT: GetValue("cmi.completion_status") - completed => 0
Thu, 17 Mar 2011 16:26:32 GMT: SetValue("cmi.exit", "normal") => 0
Thu, 17 Mar 2011 16:26:32 GMT: Terminate("", "") => 0

This happens for both student and admin account roles that we have tested. We're testing using Moodle 2.0.2 with Xampp Lite 1.7.3.

I should also add that based on your bug #MDL-26863, I downloaded and tested the Diagnostic SCO for SCORM 2004. Again, the set variables, this time with cmi.score.scaled using the provided demo script, are not stored to the Gradebook. (I would assume the grade that should be displayed in the gradebook would be 94.) The below log is for the Diagnostic SCO.

SCORM API Activity Log

Thu, 17 Mar 2011 18:12:10 GMT: Moodle SCORM 1.2 API Loaded, Activity: diagSCO, SCO: DB4B88FC-DD3A-11DA-9B41-B622A1EF5492
Thu, 17 Mar 2011 18:12:55 GMT: Initialize("", "") => 0
Thu, 17 Mar 2011 18:12:55 GMT: GetValue("cmi.entry") - ab-initio => 0
Thu, 17 Mar 2011 18:12:55 GMT: SetValue("cmi.exit", "suspend") => 0
Thu, 17 Mar 2011 18:12:55 GMT: GetValue("cmi.completion_status") - unknown => 0
Thu, 17 Mar 2011 18:12:55 GMT: GetValue("cmi.success_status") - unknown => 0
Thu, 17 Mar 2011 18:12:55 GMT: GetValue("cmi.score.scaled") - => 403
Thu, 17 Mar 2011 18:12:56 GMT: SetValue("cmi.completion_status", "incomplete") => 0
Thu, 17 Mar 2011 18:12:57 GMT: Commit("", "") => 0
Thu, 17 Mar 2011 18:12:57 GMT: GetValue("cmi.scaled_passing_score") - => 403
Thu, 17 Mar 2011 18:12:57 GMT: SetValue("cmi.score.scaled", "0.94") => 0
Thu, 17 Mar 2011 18:12:57 GMT: SetValue("cmi.success_status", "failed") => 0
Thu, 17 Mar 2011 18:12:57 GMT: GetValue("cmi.success_status") - failed => 0
Thu, 17 Mar 2011 18:12:57 GMT: SetValue("cmi.exit", "") => 0
Thu, 17 Mar 2011 18:12:57 GMT: Terminate("", "") => 0

 

Thanks,

Adam Schuldt

In reply to Adam Schuldt

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Adam,
I didn't realize that you were talking about failures in the grades data, not the tracking ones: the "SCORM API Activity Log" reports the communication between the content and Moodle, not the extra logic Moodle could perform on those data, e.g. the Gradebook.

BTW, gradebook will be updated for each SCO only in case of completion or on passing a score. See the code below (mod/scorm/locallib.php::scorm_insert_track()) which is quite self explanatory about the conditions and the current SCORM 2004 support status:

    if (strstr($element, '.score.raw') ||
        (($element == 'cmi.core.lesson_status' || $element == 'cmi.completion_status') && ($track->value == 'completed' || $track->value == 'passed'))) {
        $scorm = $DB->get_record('scorm', array('id' => $scormid));
        include_once($CFG->dirroot.'/mod/scorm/lib.php');
        scorm_update_grades($scorm, $userid);
    }

Until Moodle will fully support SCORM 2004 you need to write down even cmi.score.raw while writing down cmi.core.scaled, the last being correctly used to evaluate any Mastery Score value.

That being said, looking at your logs, on Moodle 2.0:

  • Logs #1 - It should work: spare time permitted, I'll try to replicate the sequence of calls to understand where the issue should be in 2.0;
  • Logs #2 - It cannot work.

HTH,
Matteo

In reply to Matteo Scaramuccia

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Adam,
back again on topic. Using the "SCORM Diagnostic SCO", tab "Scripted test", with this sequence:

Initialize("")
SetValue("cmi.completion_status","incomplete")
SetValue("cmi.score.min","0")
SetValue("cmi.score.max","10")
SetValue("cmi.score.raw","4")
SetValue("cmi.completion_status","completed")
Commit("")
SetValue("cmi.exit","normal")
Terminate("")

using a kind interval of 500ms, Moodle gives up with a 404 error indicating a missing parameter, the id:

  • Commit Data: id=&sesskey=dFmew2RmNS&cmi__score__raw=4&cmi__score__min=0&cmi__score__max=10&cmi__completion_status=completed&attempt=1&scoid=4;
  • Terminate Data: id=&sesskey=dFmew2RmNS&cmi__total_time=P&cmi__score__raw=4&cmi__score__min=0&cmi__score__max=10&cmi__completion_status=completed&cmi__exit=normal&attempt=1&scoid=4.

Definitely a bug on the SCORM 2004 support: MDL-26880.

HTH,
Matteo

In reply to Matteo Scaramuccia

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Adam Schuldt -

Thanks for looking into this problem, Matteo.

 

I double checked the 1.2 test package to make sure the score was recorded, and there were no problems. I guess until the bug is repaired, we can use SCORM 1.2 as a workaround.

In reply to Adam Schuldt

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Adam,
here is the summary:

  1. MDL-26863, a minor bug about showing what API has been really loaded;
  2. MDL-26880, the blocking issue on storing SCORM 2004 tracking data and then grades data in Moodle 2.0;
  3. MDL-26894, a minor bug about PHP notices which are normally not shown in production environments.

Regardless the incomplete support of SCORM 2004 in Moodle, I kindly suggest to stay with SCORM 1.2 if you're not <in need>/<ready> to use what could be available with the complex&powerful sequencing world of SCORM 2004.

HTH,
Matteo

In reply to Matteo Scaramuccia

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Joe Flaherty -

Matteo,

Thanks for the help, so until 2.0.3 we are unlikely to see a SCORM 2004 course working?

Unfortunatly, it's not really an option for us to back track to 1.2. All of our vendors and our providers refuse to work in 1.2. We'll just have to stay with the earlier version of Moodle till the problem is fixed.

In reply to Joe Flaherty

Re: SCORM 2004 Courses Not Working In Moodle 2.0

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Joe,
my proposals should be reviewed in the next weeks so it could be possible that they will be available within a WEEKLY, 2.0.2+, even if right now they are marked for 2.0.3.

HTH,
Matteo