Jump to content

Recommended Posts

Hi I'm working on module that is using Cron. I have set all I need and when I go to file skl_advancedsubscriber-cron.php (the one I quote below) directly, script runs OK. As you can see, I am using FileLogger to get output to logfile.


$file = _PS_ROOT_DIR_ . '/app/logs/cronTest.log';
$logger = new FileLogger();
$logger->logMessage('Include', 1);

$logger->logMessage('Trying init MailChimpIntegrationOverride', 1);
$McOverride = new MailChimpIntegrationOverride();
$logger->logMessage('Init MailChimpIntegrationOverride', 1);
Configuration::updateValue('SKL_EMAILSUBSCRIPTION_GDPR_LAST_UPDATE', Date("Y-m-d H:i:s", Time()));

But when I use system CRON, suddenly my script stops on line 

$McOverride = new MailChimpIntegrationOverride();

By changing 'include' to 'require' I realized script can't access to Mailchimp overriding class override/modules/mailchimpintegration/mailchimpintegration.php

Please note this file DOES NOT CHANGE, when I access skl_advancedsubscriber-cron.php directly I get input I am expecting, but when CRON scheduled task is trying to access this, script ends with HTTP500.

Anyone having experience with this? Any idea what might be a solution?

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More