Fatal error keeps on appearing

I keep on getting fatal errors on a dev site I am working on:

Fatal error : Uncaught Error: Class ‘tubepress_event_impl_tickertape_EventDispatcher’ not found in /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php:2860 Stack trace: #0 /data/55/0/45/34/697849/user/711723/htdocs/wp-content/plugins/tubepress_pro_5_1_8/vendor/symfony/dependency-injection/Container.php(314): TubePressServiceContainer->getTubepressApiEventEventdispatcherinterfaceService() #1 /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php(3605): Symfony\Component\DependencyInjection\Container->get(‘tubepress_api_e…’) #2 /data/55/0/45/34/697849/user/711723/htdocs/wp-content/plugins/tubepress_pro_5_1_8/vendor/symfony/dependency-injection/Container.php(314): TubePressServiceContainer->getTubepressApiOptionsReferenceinterfaceService() #3 /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php(3306): Symfony\Component\DependencyInjection\Container->get('tubepress_a in /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php on line 2860

I keep clearing the system cache as described on http://support.tubepress.com/customer/portal/articles/2048959-the-system-cache and the site works after that, but this is happening every day and I would like to get the issue fixed before we launch the site in a few days.

Any suggestions to prevent this from happening every day? The dev site is https://005d4da.netsolhost.com/

Typically we’ve seen this error when there’s a corrupt/incomplete installation, but it’s unusual that it’s happening sporadically. Would you verify that there’s only one copy of TubePress installed at wp-content/plugins? In other words, /wp-content/plugins/tubepress_pro_5_1_8/ should be the only TubePress directory inside wp-content/plugins.

If you are willing and able to share FTP and/or WP credentials, we’d be happy to log in and take a look as well.

Thanks! Just emailed it to you via the contact form.

Thank you. We were able to log in and verify that you indeed have only one copy of TubePress at wp-content/plugins. We think what’s happening is that something is corrupting your TubePress system cache every night. It’s very likely just your web server performing routine maintenance by clearing out the /tmp directory. To give this theory a test, what we can do is tell TubePress to store its system cache somewhere else where it won’t be touched. To do this, you simply need to make an edit to a configuration file:

  1. On your website you should have a file at htdocs/wp-content/tubepress-content/config/settings.php. Open this file with your favorite text editor.

  2. Around line 68 of that file, you should see a line that looks like this: //'directory' => '/some/directory'

  3. Change that line to: 'directory' => __DIR__ . '/../system-cache',

  4. Save the file and re-upload it to your web server, overwriting the original.

  5. Hit the refresh button on your browser to invoke the changes.

  6. Verify that you now have a directory at htdocs/wp-content/tubepress-content/system-cache

That should be a permanent fix, but we will likely have to wait until tomorrow morning to know for sure. Give it a try?

Thanks! Just to confirm, for #3, line 68 now reads:

//‘directory’ => DIR . ‘/…/system-cache’,

Correct? Or am I supposed to remove the // at the beginning?

For #6, am I supposed to manually create the /system-cache folder or is it supposed to appear automatically?

The website was working OK all day and then nighttime hits and I am getting the error again:

Fatal error : Uncaught Error: Class ‘tubepress_event_impl_tickertape_EventDispatcher’ not found in /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php:2860 Stack trace: #0 /data/55/0/45/34/697849/user/711723/htdocs/wp-content/plugins/tubepress_pro_5_1_8/vendor/symfony/dependency-injection/Container.php(314): TubePressServiceContainer->getTubepressApiEventEventdispatcherinterfaceService() #1 /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php(3605): Symfony\Component\DependencyInjection\Container->get(‘tubepress_api_e…’) #2 /data/55/0/45/34/697849/user/711723/htdocs/wp-content/plugins/tubepress_pro_5_1_8/vendor/symfony/dependency-injection/Container.php(314): TubePressServiceContainer->getTubepressApiOptionsReferenceinterfaceService() #3 /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php(3306): Symfony\Component\DependencyInjection\Container->get('tubepress_a in /tmp/tubepress-system-cache-e496cfb1f59d7ad85ea441773bfca551/tubepress-5.1.8/TubePressServiceContainer.php on line 2860

As you can see from last night’s error message, TubePress is still using /tmp.

Line 68 should read:

 'directory' => __DIR__ . '/../system-cache',

Go ahead and copy/paste that line, just to ensure there’s no syntax errors. Alternatively, if you’re willing and able to share FTP credentials with us, we’ll be glad to log in and make the edit for you.

TubePress should be able to create that directory on your behalf, but you are free to create it if you’d like.

We should be able to get this sorted out today! Thanks

Thanks! I replaced line 68 with the line of code you sent and it automatically created the system-cache folder so hopefully this will work. I will let you know if we have any more issues.

Fingers crossed that will do the trick. But if not, definitely let us know and we’ll keep digging!