[V2.6] Suspend Data issues.

[V2.6] Suspend Data issues.

by Hugh Edwards -
Number of replies: 5

Hi All. 

I'm getting some quite random cmi.suspend_data losses from my scorm 1.2 course. The problem manifests itself in that its creating resume problems where the resume isn't resuming to the right place. 

Here is an excerpt from the API Log:

Wed, 15 Jan 2014 22:12:24 GMT: LMSSetValue("cmi.suspend_data", "3_01~2g2q0Y001v0M051n06171Z0N0$091u0f0D0r0h040g0Q060t0J0S0j0T080I0X0k0a0c0H0a1o0W0d0V0b1P0l0_0F0A0U0C0i0z0G04150s07031y081K0B0p0e090E0R021O0x0L011b0w0m0~266~226100101a~2T50101101111012110131101411015110161101711018110191101a1101b1101c11010120111201212013120141201013011130121301313014130101401114012140131401414015140161401714018140191401a14018140191401a140101501115012150131501016011160121601316014160101701117012170131701417015170161701717018170191701a1701b1701c170101801118012180131801418015180161801718018180101901119012190131901419015190101a~2T1c100000000000004axis7StudenteStudentSirname1010101000000000000000000000000000000000000000000000000000000000000000000000000~2H3~2n1cb101001a1a103g$0BjDi3000O1118_default6Ai00416Ai00002Agro03s21fe720118_default000000010~241cb101001a1a113pF0j2AgfDg30118_defaultqn02ukfe720118_default000000010~241cb101001a1a113DP0j2AgfDg30118_defaultqn025ife720118_default000000010~2Qa~2U1cb101001a1a103ge1~2416Ai00c26Ai00S0jDi3000J3118_default6Ai00006Ai00x1jDi3000T2118_defaultqn02Pofe720118_default000000010Vcb101001a1a103_V0214qn02kafe720118_default0000000702t22x3Ucb101001a1a112wg214qn02Vdfe720118_default0000000702r32O3Ucb101001a1a122pf214qn02kdfe720118_default0000000702H42P5Ucb101001a1a132mo214qn02Kife720118_default0000000702w32W6~241cb101001a1a113iN0j2AgfDg30118_defaultqn02vgfe720118_default000000010~2S1cb101001a1a103he1~2216Ai0000jDi3000o3118_defaultfDg30118_defaultfDg30118_default6Ai00y2qn02Klfe720118_default000000010~251cb101001a1a113be1j2AgfDg30118_defaultro03ze1fe720118_default000000010~241cb101001a1a113Ce1j2AgfDg30118_defaultqn02hlfe720118_default000000010~2O6~2Z3cb101001a1a103ae1~283jDi3000o4118_defaultjDi3000c2118_defaultjDi3000m1118_defaultjDi3000J3118_defaultjDi3000p6118_defaultjDi3000H0118_defaultjDi3000K5118_defaultjDi300000118_defaultjDi300023118_defaultjDi300035118_defaultro03ze1fe720118_default000000010~2J2cb101001a1a103Ae1~2U1jDi3000m1118_defaultjDi3000H0118_defaultjDi300000118_defaultjDi300012118_defaultjDi3000n3118_defaultjDi3000I2118_defaultro03be1fe720118_default000000010~2z3~231cb101001a1a103ue1i2Ag5Cg0112Ag5Cg010qn02blfe720118_default000000010~2o2cb101001a1a103Be1~2z12AgjDi3000H0118_defaultjDi300000118_defaultfDg30118_defaultjDi300012118_defaultjDi3000I2118_defaultro03BG0fe720118_default000000010~24e~2H1cb101001a1a103S21V6Ai00m16Ai00I26Ai0000fDg30118_defaultjDi300012118_defaultro032x0fe720118_default000000010~241cb101001a1a103le1jfDg30118_default2Agqn02qmfe720118_default000000010~241cb101001a1a103MT0jfDg30118_default2Agqn022kfe720118_default000000010~2k1cb101001a1a103me1yjDi300082118_default6Ai00006Ai0041ro03Gy0fe720118_default000000010~241cb101001a1a103q11jfDg30118_default2Agqn02Wife720118_default000000010~2f1cb101001a1a123sP0u6Ai00416Ai0000fDg30118_defaultqn025kfe720118_default000000010~241cb101001a1a103fe1jfDg30118_default2Agqn020tfe720118_default000000010~2m1cb101001a1a1035M0BjDi3000K0118_default6Ai00s16Ai00002Agqn02Bkfe720118_default000000010~2S1cb101001a1a103be1~221fSiM4k2_$a5g0016fSiM4h1_$a5k2017fSiM4f0_$a5i10185Cg0135Cg0145Cg015qn02Wpfe720118_default000000010Wcb101001a1a103je187Cg03012ro03re1fe720118_default000000010Wcb101001a1a103$b198Cg04axisqn02tqfe720118_default000000010~2sa~2y1cb101001a1a103n61M6Ai00126Ai00H06Ai00006Ai00m1jDi3000I2118_defaultro03tz0fe720118_default000000010~241cb101001a1a1034S0jfDg30118_default2Agqn02ukfe720118_default000000010~2x1cb101001a1a103$H0M6Ai00m16Ai00I26Ai00126Ai0000jDi3000H0118_defaultqn020jfe720118_default000000010~2r2cb101001a1a103ue1~2D12AgjDi3000S0118_defaultjDi300000118_defaultjDi3000n2118_defaultjDi3000d3118_defaultjDi3000x1118_defaultqn02Wrfe720118_default000000010~241cb101001a1a113_71j2AgfDg30118_defaultqn02zife720118_default000000010~2u2cb101001a1a103ie1~2G1jDi300000118_default6Ai00H02AgfDg30118_defaultjDi3000J3118_defaultjDi3000o4118_defaultjDi3000m1118_defaultqn021kfe720118_default000000010~2A4~2l3cb101001a1a103ue1~2x2jDi3000K4118_default6Ai00n26Ai00U3jDi3000x1118_defaultjDi300000118_defaultjDi3000L6118_default6Ai00S0jDi3000p5118_defaultjDi300023118_defaultjDi300046118_defaultqn02Bnfe720118_default000000010~271cb101001a1a1037X0mfDg30118_default2Ag2Agqn02Eofe720118_default00000001000000000000000") => 405
Wed, 15 Jan 2014 22:12:24 GMT: LMSGetErrorString("405", "Incorrect data type") => 0
Wed, 15 Jan 2014 22:12:24 GMT: LMSGetDiagnostic("405", "405") => 0
 
So I then did a manual update of the database row as follows:
 

UPDATE `mysql5_932830_gftbtest`.`mdl_scorm_scoes_track` SET `value`='3_01~2g2q0Y001v0M051n06171Z0N0$091u0f0D0r0h040g0Q060t0J0S0j0T080I0X0k0a0c0H0a1o0W0d0V0b1P0l0_0F0A0U0C0i0z0G04150s07031y081K0B0p0e090E0R021O0x0L011b0w0m0~266~226100101a~2T50101101111012110131101411015110161101711018110191101a1101b1101c11010120111201212013120141201013011130121301313014130101401114012140131401414015140161401714018140191401a14018140191401a140101501115012150131501016011160121601316014160101701117012170131701417015170161701717018170191701a1701b1701c170101801118012180131801418015180161801718018180101901119012190131901419015190101a~2T1c100000000000004axis7StudenteStudentSirname1010101000000000000000000000000000000000000000000000000000000000000000000000000~2H3~2n1cb101001a1a103g$0BjDi3000O1118_default6Ai00416Ai00002Agro03s21fe720118_default000000010~241cb101001a1a113pF0j2AgfDg30118_defaultqn02ukfe720118_default000000010~241cb101001a1a113DP0j2AgfDg30118_defaultqn025ife720118_default000000010~2Qa~2U1cb101001a1a103ge1~2416Ai00c26Ai00S0jDi3000J3118_default6Ai00006Ai00x1jDi3000T2118_defaultqn02Pofe720118_default000000010Vcb101001a1a103_V0214qn02kafe720118_default0000000702t22x3Ucb101001a1a112wg214qn02Vdfe720118_default0000000702r32O3Ucb101001a1a122pf214qn02kdfe720118_default0000000702H42P5Ucb101001a1a132mo214qn02Kife720118_default0000000702w32W6~241cb101001a1a113iN0j2AgfDg30118_defaultqn02vgfe720118_default000000010~2S1cb101001a1a103he1~2216Ai0000jDi3000o3118_defaultfDg30118_defaultfDg30118_default6Ai00y2qn02Klfe720118_default000000010~251cb101001a1a113be1j2AgfDg30118_defaultro03ze1fe720118_default000000010~241cb101001a1a113Ce1j2AgfDg30118_defaultqn02hlfe720118_default000000010~2O6~2Z3cb101001a1a103ae1~283jDi3000o4118_defaultjDi3000c2118_defaultjDi3000m1118_defaultjDi3000J3118_defaultjDi3000p6118_defaultjDi3000H0118_defaultjDi3000K5118_defaultjDi300000118_defaultjDi300023118_defaultjDi300035118_defaultro03ze1fe720118_default000000010~2J2cb101001a1a103Ae1~2U1jDi3000m1118_defaultjDi3000H0118_defaultjDi300000118_defaultjDi300012118_defaultjDi3000n3118_defaultjDi3000I2118_defaultro03be1fe720118_default000000010~2z3~231cb101001a1a103ue1i2Ag5Cg0112Ag5Cg010qn02blfe720118_default000000010~2o2cb101001a1a103Be1~2z12AgjDi3000H0118_defaultjDi300000118_defaultfDg30118_defaultjDi300012118_defaultjDi3000I2118_defaultro03BG0fe720118_default000000010~24e~2H1cb101001a1a103S21V6Ai00m16Ai00I26Ai0000fDg30118_defaultjDi300012118_defaultro032x0fe720118_default000000010~241cb101001a1a103le1jfDg30118_default2Agqn02qmfe720118_default000000010~241cb101001a1a103MT0jfDg30118_default2Agqn022kfe720118_default000000010~2k1cb101001a1a103me1yjDi300082118_default6Ai00006Ai0041ro03Gy0fe720118_default000000010~241cb101001a1a103q11jfDg30118_default2Agqn02Wife720118_default000000010~2f1cb101001a1a123sP0u6Ai00416Ai0000fDg30118_defaultqn025kfe720118_default000000010~241cb101001a1a103fe1jfDg30118_default2Agqn020tfe720118_default000000010~2m1cb101001a1a1035M0BjDi3000K0118_default6Ai00s16Ai00002Agqn02Bkfe720118_default000000010~2S1cb101001a1a103be1~221fSiM4k2_$a5g0016fSiM4h1_$a5k2017fSiM4f0_$a5i10185Cg0135Cg0145Cg015qn02Wpfe720118_default000000010Wcb101001a1a103je187Cg03012ro03re1fe720118_default000000010Wcb101001a1a103$b198Cg04axisqn02tqfe720118_default000000010~2sa~2y1cb101001a1a103n61M6Ai00126Ai00H06Ai00006Ai00m1jDi3000I2118_defaultro03tz0fe720118_default000000010~241cb101001a1a1034S0jfDg30118_default2Agqn02ukfe720118_default000000010~2x1cb101001a1a103$H0M6Ai00m16Ai00I26Ai00126Ai0000jDi3000H0118_defaultqn020jfe720118_default000000010~2r2cb101001a1a103ue1~2D12AgjDi3000S0118_defaultjDi300000118_defaultjDi3000n2118_defaultjDi3000d3118_defaultjDi3000x1118_defaultqn02Wrfe720118_default000000010~241cb101001a1a113_71j2AgfDg30118_defaultqn02zife720118_default000000010~2u2cb101001a1a103ie1~2G1jDi300000118_default6Ai00H02AgfDg30118_defaultjDi3000J3118_defaultjDi3000o4118_defaultjDi3000m1118_defaultqn021kfe720118_default000000010~2A4~2l3cb101001a1a103ue1~2x2jDi3000K4118_default6Ai00n26Ai00U3jDi3000x1118_defaultjDi300000118_defaultjDi3000L6118_default6Ai00S0jDi3000p5118_defaultjDi300023118_defaultjDi300046118_defaultqn02Bnfe720118_default000000010~271cb101001a1a1037X0mfDg30118_default2Ag2Agqn02Eofe720118_default00000001000000000000000' WHERE `id`='44403';

...And it updated it into the MySQL db fine. 

I get these quite a lot, and it's a real bind for my users as they never resume properly. It's created in Articulate Storyline (latest version) and it doesn't seem to matter if it's in Chrome or Firefox etc.

Needless to say, everything else goes through the course fine, and the scoring tracks well, it's just not resuming at the right point due to the errors with the suspend data.  

I'd really appreciate any help anyone can give on this...

Hugh. smile 

Average of ratings: -
In reply to Hugh Edwards

Re: [V2.6] Suspend Data issues.

by Dan Marsden -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Plugins guardians Picture of Testers Picture of Translators

The SCORM 1.2 spec limits the amount of data that can be stored in suspend_data - it states that suspend_data should not be over 4096 characters and if it is over that amount the SCORM spec dictates that we must return an error which you are seeing there.

When testing an LMS for SCORM compliance one of the tests that the ADL tests do on the LMS is a specific check for this so we need to make sure Moodle complies... but it's a really stupid requirement and a lot of SCORM packages don't follow the requirement properly either. The SCORM 2004 spec changes this particular requirement and makes it more
flexible but as Moodle doesn't provide support for SCORM 2004 you need to manage it slightly differently.

To make your local Moodle site work properly you need to find this line in mod/scorm/datamodels/scorm_12.js.php
CMIString4096 = '^[\\u0000-\\uffff]{0,4096}$';


and change it to something like:
CMIString4096 = '^[\\u0000-\\uffff]{0,40960}$';

(note the extra 0 on the 4096 at the end of that string.)

Then clear your browser cache and it might work correctly.

I have a tracker issue (MDL-41476) to add a setting in Moodle that allows us to break SCORM compliance and extend the data limits so that SCORM packages like this one work correctly without any code changes.
Average of ratings: Useful (1)
In reply to Dan Marsden

Re: [V2.6] Suspend Data issues.

by Hugh Edwards -

Just a further update on that (again provided by Dan) - I was also having problems with a couple of questions which were also failing. The API logs were as follows:

> Wed, 15 Jan 2014 22:09:20 GMT:

> LMSSetValue("cmi.interactions.24.student_response", "A_'Plosive'_is.when_a_blast_of_air_hits_the_mic'_capsule__making_a_'bump_spike'__usually_made_with_P's_or_B's,The_'Bass_Proximity_Effect'_is.an_artificial_increase_in_the_bass-tone_of_a_recording_made_by_getting_closer_then_necessary_to_the_mic.,A_'Mic-Pop'_is.undefined")=> 405

> Wed, 15 Jan 2014 22:09:20 GMT: LMSGetErrorString("405", "Incorrect data type") => 0

> Wed, 15 Jan 2014 22:09:20 GMT: LMSGetDiagnostic("405", "405") => 0 

and Dan's fix was:

"That error is another issue with limits on the amount of data that can be stored in certain params - that one has a limit of 255 chars. The line above the 4096 one looks like this:

CMIString256 = '^[\\u0000-\\uffff]{0,255}$';

change the 255 on the end to something higher like this:
CMIString256 = '^[\\u0000-\\uffff]{0,2550}$';"

Just thought I'd share it - Thanks Dan! smile 

Average of ratings: Useful (1)
In reply to Hugh Edwards

Re: [V2.6] Suspend Data issues.

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

Hi Hugh,
it's worth nothing that your package is not SCORM 1.2 compliant in terms of tracking - it won't run in other LMSs too - since the content is generating data whose size is far from the limits imposed by the Data Model as described in SCORM 1.2 and tested by the ADL Test Suite.

I guess you're trying to overcome SCORM 1.2 Data Model limits and you're using Moodle as the LMS, using the OSS nature of it to hack the size of some Data Model elements, to create kind of strong link between the Sharable Content and your Moodle instance.

Matteo

In reply to Matteo Scaramuccia

Re: [V2.6] Suspend Data issues.

by Hugh Edwards -

HI Matteo. 

THank you for that. It's a good point. However, it's the only way to have Scorm 1.2 courses as large as mine track without errors. smile

In reply to Hugh Edwards

Re: [V2.6] Suspend Data issues.

by Alain St-Gelais -

In moodle V3.0, there is a config that you should try to uncheck here  : 

Site administration / ► Plugins / ► Activity modules / ► SCORM package

Look at the Admin settings

Enable SCORM 1.2 standard mode

Disabling this setting allows Moodle to store more data than the SCORM 1.2 specification allows. If your SCORM packages allow users to enter large amounts of text or if your package tries to store large amounts of data in the suspend_data field disable this.

Hope this help to resolve issue for anyone!

Average of ratings: Useful (1)