Closed ewallah closed 1 year ago
I have the same problem here, any news on this bug?
A possible solution can be to use a $page variable instead of the global $PAGE see
This way you avoid using the global $PAGE, as there is no global $PAGE available during cron, the function runs in the background without user interface.
A possible solution can be to use a $page variable instead of the global $PAGE see
This way you avoid using the global $PAGE, as there is no global $PAGE available during cron, the function runs in the background without user interface. Thank you @ewallah, it worked on my instance!
Closing as a duplicate of #443. @ewallah are you able to create a pull request to fix this?
The error is " Coding problem: unsupported modification of PAGE->context from 70 to 70" and the problem is trying to change the context on the global $PAGE variable, but since it tries to change to the same value why don't you just leave that statement $PAGE->set_context($context); out?
Using the global $PAGE in a scheduled task only works when you execute the task inside the browser. During cron, there is no $PAGE available.
Execute scheduled task: mod_customcert\task\email_certificate_task ... started 05:21:02. Current memory use 29MB. ++ Coding problem: unsupported modification of PAGE->context from 70 to 70 ++