How do the autoupdate settings work?

How do the autoupdate settings work?

by J Rogers -
Number of replies: 11
Possibly the least-documented feature of the Moodle SCORM module is what the "autoupdate" field means. The options are "Never", "Whenever it changes", "Every day", and "Every time it's used".

"Every day" is not immediate enough to reflect the changes I just uploaded.

"Every time it's used," as I interpret it, would mean that the SCORM lesson updates itself every time a student accesses it, which would mean a lot of unnecessary disk access and "updating" as 100+students access the SCORM and it updates each time.

"Whenever it changes" is the only option that makes sense for my purposes, but I can't seem to get it work.


How does Moodle know when a module has changed? I haven't seen any evidence that Moodle recognizes SCORM package changes or updates packages automatically.

What I have discovered is that, apparently, if the filename field is unchanged (even if I explicitly "choose" a different SCORM with the same name), there is no checking to see if the contents are different.


If someone could explain to me how SCORM updating works, and how I can trigger it, it could significantly optimize my workflow (and i would be eternally grateful!)

Thanks in advance,
Jeremy
Average of ratings: -
In reply to J Rogers

Re: How do the autoupdate settings work?

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
Hi Jeremy,

I think the way it's supposed to work is that it checks the md5 of the file against the md5hash stored in the scorm table for that scorm object, and if they don't match, it should update the files that it unzips into the moddata directory.

I think its designed so you can update the original zip file without updating the module in moodle, but by overwriting the original file via some other method.

Is this not working?

thanks,

smile

Dan
In reply to Dan Marsden

Re: How do the autoupdate settings work?

by J Rogers -
I've been using 9.1.1 for three months now, and have never seen any indication of update working.

When I choose a file with the same name (but with different contents) as a replacement for a SCORM package, nothing gets updated. The old scorm version plays.

One thing I've had to do is put the files into the proper moodledata directory via FTP. The in-Moodle upload prompt doesn't work for me.

When does the md5 hash get updated? If it's from the upload prompt, that might explain why Moodle never acknowledges a change.

Steps for reproducing this bug:

1. create two SCORM packages with different content, scorm1.zip and scorm2.zip .
2. upload scorm1.zip to moodle [via FTP]
3. create a new scorm activity. choose scorm1.zip. save activity.
4. rename scorm2.zip to scorm1.zip on local computer.
5. upload new scorm1.zip to moodle [via FTP]
6. edit activity created in 3. choose scorm1.zip again. save activity again.

Results: original scorm1.zip's SCORM module is displayed. No update was ever performed.

I've tried various combinations of "autoupdate" settings, with the same results.

The only way I've gotten things to update is more of a "wipe" approach. I associate the SCORM package to the activity in this order: scorm1(orig)->temporary scorm package [wipes out old scorm1, replaces with temp. pkg]->scorm1(new) [wipes out temporary scorm package, replaces with scorm1(new)].

Is this how it's expected to work?
In reply to J Rogers

Re: How do the autoupdate settings work?

by Bradley Bailey -

Maybe you guys are talking about a seperate issue, but I was having problem updating SCORM presentations a few months ago.

I realized that part of my problem was that I was not deleting my temporary internet files (cache). As soon as I cleared my cache, it played my updated presentation. I got that advice from this forum =)

I have never figured out the functionality of the auto-update feature.

Average of ratings: Useful (1)
In reply to Bradley Bailey

Re: How do the autoupdate settings work?

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
thanks Bradley - that's good advice!

Jeremy, can you please check to see if it's a caching issue in your browser?

if not, can you please log a new bug in the tracker for this?

thanks!

smile

Dan

In reply to Dan Marsden

Re: How do the autoupdate settings work?

by J Rogers -
This is not a caching issue. I thought I mentioned that earlier, but it may have been mentally edited out... I am aware of the the caching issue and hope that will be addressed as well - how can we ensure that learners are using the most recent scorm?

I still haven't gotten a clarification of the expected behavior of the autoupdate system. Could someone please explain it? Thank you.


In reply to J Rogers

Re: How do the autoupdate settings work?

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
as mentioned above, "I think its designed so you can update the original zip file without updating the module in moodle, but by overwriting the original file via some other method."

so you upload a scorm.zip file to moodle,

behind the scenes it extracts it, and stores it in moddata

when autoupdate is triggered (on student load etc) it checks the md5 of the scorm.zip file and compares that to what the md5 is set to in the scorm table.

if it's different - it triggers an "update" process to refresh the files in the unzipped directory...

so - if you set it to autoupdate "every time it's used" it won't unzip the files "every time it's used" unless the md5 of the scorm.zip file is different to the md5 stored in the db.

at least that is how I think it "should" work.....if it doesn't, then please file a bug report in the tracker.

thanks!

smile

Dan
In reply to Dan Marsden

Re: How do the autoupdate settings work?

by J Rogers -
Thanks for the explanation. Was this somewhere else, like, say, in the wiki or some FAQ? If not, it definitely needs to be! If it was somewhere else, please tell me the link! smile

I will try the various autoupdate settings and see what happens. If I could get more automated updates, that would be a huge time savings for me!

In reply to J Rogers

Re: How do the autoupdate settings work?

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
I guessed that's how it should be working by looking at the code.....should really add it to some documentation somewhere. - can you have a play and see if it works as I've explained? - you could also add a bug in the tracker asking for info about autoupdate to be added to the help pages in moodle.

thanks,

smile

Dan
In reply to Dan Marsden

Re: How do the autoupdate settings work?

by J Rogers -
I have tried it out a little bit - Tried it with some completed SCORMs in "review mode" and didn't see any updates - it was still playing old content.

I will try some other usage scenarios and see what happens. I will also post a few bug reports related to our conversation soon.

I'm almost loath to attach yet another bug report to the SCORM module - you guys have enough to handle!
In reply to J Rogers

Re: How do the autoupdate settings work?

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
Thanks Jeremy!

we're slowly getting through them!

smile

Dan
In reply to Dan Marsden

Re: How do the autoupdate settings work?

by Daniele Fontanot -

I'm having the same problem. I tried using a scorm zip uploaded into the repository folder, attached as an "alias/shortcut", and also i tried using a scorm zip uploaded to Dropbox (after adding Dropbox repository with relative procedure of API key). Whenever i change the zip file into the repository or into Dropbox, Moodle does not update the activity content, showing the old content. I tried choosing "update every time the file is used" with no result. 

Any idea? In my opinion this is something important to be fixed.

thank you.