Moodle for mobile

Resync arrow prevents SCORM package access offline

 
Picture of Anton Kassimov
Resync arrow prevents SCORM package access offline
 
In our testing of the Mobile Moodle app v3.4.2, we noticed that if we download and open a lesson, make progress, return to the SCORM tree page and lose internet connection on that tree page, we're no longer able to re-enter the course. We see a "there was a problem connceting to the site. Please check your connection an try again." message.


I believe this is happenining because the app would like to make sure that it'll show you the latest version of your content, so it tries to check and pull any updates from the mothership (the web LMS). 

Would it possible to somehow allow the student to open the content regardless of this check? Even if the SCORM package is out of date? Or am I misunderstanding the reason for this error?

This is a big risk for us because if a client loses connection while on that SCORM tree page, they won't be able to access the content again until they regain wifi, even though their content is downloaded and should be available to them. 

Thank you in advance for the your help,

Anton 

 
Average of ratings: -
Picture of Anton Kassimov
Re: Resync arrow prevents SCORM package access offline
 

After some digging, I believe the issue we're experiencing is possily related to this bug: https://tracker.moodle.org/browse/MOBILE-1972

When the refresh arrow appears and we lose connection, the arrow prevents us from accessing the content eventhough the actual files on our server haven't changed.

Would anyone have any idea of how to get past this roadblock? 


 
Average of ratings: -
Picture of Dani Palou
Re: Resync arrow prevents SCORM package access offline
Core developersMoodle HQParticularly helpful MoodlersPlugin developers

Hi Anton,

we're aware of this issue, we created this issue a while ago:

https://tracker.moodle.org/browse/MOBILE-2114

It's a tricky issue to solve. Right now the only possible solution is to re-download all the data after the user sends any data to the site, but that would increase the data usage a lot, that's why we haven't fixed it yet, we're looking for a better solution.

Kind regards,

Dani

 
Average of ratings: -
Picture of Arthur Medoum
Re: Resync arrow prevents SCORM package access offline
 

Hello all,

here is my approach to reach the objective that Anton is describing.


The issue:  It is not possible to re-enter a Course after you lose Internet connection at the scorm tree page. We would like to still be able to access the content (the downloaded SCORM) at this point even though we are offline.


The solution i took: Most of the components have a refresh functionnality called when the page loads. That refresh functionnality starts by clearing the component cached data and then load the component data,  for the case of Scorm, it will reload (the scorm user data, scorm scoes, the scorm by courses...) from the regular LMS and store it in the cache again.

My approach was to prevent  the clearance of the targetted resource (scorm data)  from the cache, this way the App always retrieve them and does not decide to go fetch a new copy of the resource when the page loads and  also on manual refresh from the User.

It works to reach my goal. But i am wondering if i broke something at a deeper Level. 

*Here are the files that i have changed:

 www/addons/mod/scorm/controllers/index.js
www/core/components/course/controllers/section.js


*here are the file differences (attached)



 
Average of ratings: -
Picture of Dani Palou
Re: Resync arrow prevents SCORM package access offline
Core developersMoodle HQParticularly helpful MoodlersPlugin developers

Hi Arthur,

the main issue with that approach is that now the user is unable to refresh the data. If he performs a Pull To Refresh, he will still get the cached data.

IMO it would be better to modify the $scope.open function in scorm/controllers/index.js to do something like this:

                    downloadScormPackage().then(function() {

                        // Success downloading, open scorm if user hasn't left the view.

                        if (!$scope.$$destroyed) {

                            openScorm(scoId);

                        }

                    }).catch(function(error) {

                        if (!$scope.$$destroyed) {

                            if (isOutdated) {

                                openScorm(scoId);

                            } else {

                                $mmaModScormHelper.showDownloadError(scorm, error);

                            }

                        }

                    });

This way, if the download fails when opening the SCORM you'll still open it as long as there's something downloaded. Please notice that this can cause problems if the user has modified some data in web or the package was modified.

I haven't tested this solution, so maybe you'll have to change more things.

Cheers,

Dani

 
Average of ratings: -
Picture of Anton Kassimov
Re: Resync arrow prevents SCORM package access offline
 

Thank you, Dani!

We put your idea to the test, and preliminary testing is definitely giving us the desired behavior. We will do more thorough testing in the coming weeks and will share our findings, but for now I just wanted to thank you for taking the time to share this option with us. You have no idea how helpful that was to us! 

I'm curious, will this still be an issue in Moodle Mobile 3.5? Or are you still looking for the ultimate solution to this problem?

Thanks again,

Anton

 
Average of ratings: -
Picture of Dani Palou
Re: Resync arrow prevents SCORM package access offline
Core developersMoodle HQParticularly helpful MoodlersPlugin developers

Hi Anton,

sorry for the delay in answering. Yes, this is still an issue in v3.5, we're still looking for an ultimate solution but it's not a simple issue, it might require some changes in Moodle web.

Cheers,

Dani

 
Average of ratings: -