Best practice forum (Archived)

Program NOT completing

 
? ?
Program NOT completing
par ? ?, Sunday 27 November 2011, 21:57
 

Hi,

I've created a Program with mandatory 2 courses and tested it by going through as a learner user. I can complete the 2 courses successfully, but the program status doesn't ever update and won't complete.

Currently we are using v1.1.3

thanks,

-Ira


Simon Coggins
Re: Program NOT completing
par Simon Coggins, Sunday 27 November 2011, 23:01
Groupe Totara

Hi Ira,

Program completion, like course completion runs on the cron, so it has to run before the progress is updated. Unfortunately currently the program management cron only runs once every day, so if it's already run that day, you may have to wait 24 hours.

Could you check again later and see if it updates?

Simon

Ce message du forum a été supprimé
Monday 28 November 2011, 00:19
Le contenu de ce message de forum a été supprimé et n'est plus accessible.
? ?
Re: Program NOT completing
par ? ?, Monday 28 November 2011, 14:07
 

Hi,

I checked it again today and it has completed. Is there any way to change this? or at a minimum change the time when it schedules?

The program we are testing will be going out to 12,000 users and it will cause lots of headaches/confusion if all of them have to wait potentially 24hrs for program completion...

-Ira

Simon Coggins
Re: Program NOT completing
par Simon Coggins, Monday 28 November 2011, 14:35
Groupe Totara

It can be changed by modifying the following line in /local/program/cron.php (L55):

$dailycron = 60 * 60 * 24; // one day

This gives the minimum number of seconds between runs - if you change it to 0 it will run on every cron run.

The reason we haven't changed this yet is that we have some concerns around performance of the program management cron - there are situations where the cron can generate a lot of database queries and that might impact on site performance.

We do want to change it at some point but as yet we haven't had time to look into the performance issues so we've left it as it is for now.

Simon

Ce message du forum a été supprimé
Thursday 5 January 2012, 08:06
Le contenu de ce message de forum a été supprimé et n'est plus accessible.
? ?
Re: Program NOT completing
par ? ?, Sunday 8 January 2012, 14:43
 

Hi Danielle,

I've just tried a quick test, a program with two coursesets, two courses in the first set and one in the second. It seemed to work as expected for me, but admittedly it was a pretty straightforward simple test.

Can you go over and detail the steps you took to set up your program to help us to reproduce the bug? Common problems to look out for would be the completion criteria that are set on individual activities within each course; and also that there is some sort of overall course completion criteria set (via the Completion link in the Course Administration block).

It would be easy to miss something here when setting up the courses in the coursesets, for example some activity that has completion criteria that aren't being met, or a missing/incorrect overall course completion criteria which is never being triggered - so the course is never marked as complete by the cronjob, and therefore the courseset never gets marked as complete. This may be a bug that requires a particular combination of completion criteria to be in place before it shows up, so the more information you can provide the easier it'll be for me to track this one down

Thanks,

Ciaran

Ce message du forum a été supprimé
Monday 9 January 2012, 01:04
Le contenu de ce message de forum a été supprimé et n'est plus accessible.
? ?
Re: Program NOT completing
par ? ?, Monday 9 January 2012, 12:36
 

Hi Dani,

We noticed the IE7 styling issue ourselves just before Christmas and a fix for that should be going out in the next release this week, but thanks for pointing it out anyway.

We've looked at this again, and really it does seem to come down to that 24-hour delay. The normal cronjob simply skips the program management completion checking for 24 hours after the last time it checked, so it wouldn't matter how often you run the cron within that 24 hour period, it'll still just ignore any subsequent program course, courseset etc completions. And as you noticed if you tell it to run the program completion check in every cron run then it works.

It is not ideal of course, and it is on the list of things to do, to refactor the code involved to remove performance bottlenecks on large sites. The only reason it does things with this 24-hour delay is because the current checks are very expensive in terms of database resources and really do cause performance problems for large live customers.

In the interim until we release a fix I'm afraid the only workaround is to set $dailycron to 0 in local/program/cron.php so that the program checks run all the time, though be aware of potential performance issues.

Sorry if this isn't of much help!

Thanks,

Ciaran

Ce message du forum a été supprimé
Sunday 11 March 2012, 20:29
Le contenu de ce message de forum a été supprimé et n'est plus accessible.
Craig Eves
Re: Program NOT completing
par Craig Eves (Totara Support), Monday 12 March 2012, 16:14
Groupe Totara

Hi Sonia

As well as enabling the completion on the face to face activity the course needs to know what activities need to be completed to complete the course.

To do this select the course > Administration > Completions > Activities completed and make sure the Face to face is ticked.

The other thing to note is that the course completion does not happen as soon as the activity is completed. The course completion processes are run periodically to ease the load on the server, this is set usually to run nightly but depends on your site.

Craig

Ce message du forum a été supprimé
Monday 12 March 2012, 17:49
Le contenu de ce message de forum a été supprimé et n'est plus accessible.
Craig Eves
Re: Program NOT completing
par Craig Eves (Totara Support), Monday 12 March 2012, 18:57
Groupe Totara

Hi Sonia

If manual completion is enabled and the self completion block is ticked then they will show on the report when the 'daily' course completion script is run.

If it doesn't another possibility is  there is a course dependency set , this means  dependent course needs to be completed first before the course can be completed.