Support » Plugin: WooCommerce » Fatal error when tyring to upgrade databsse

  • Resolved obscurant1st

    (@obscurant1st)


    When I try to upgrade the woocommerce daabase by clickin on the button which shows up in my admin area, I am getting fatal error like below:

    
    Fatal error: Uncaught RuntimeException: Error saving action: Unable to save action. in /home/try2know/public_html/wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_wpPostStore.php:33 Stack trace: #0 /home/try2know/public_html/wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_ActionFactory.php(109): ActionScheduler_wpPostStore->save_action(Object(ActionScheduler_Action)) #1 /home/try2know/public_html/wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_ActionFactory.php(59): ActionScheduler_ActionFactory->store(Object(ActionScheduler_Action)) #2 /home/try2know/public_html/wp-content/plugins/woocommerce/includes/libraries/action-scheduler/functions.php(18): ActionScheduler_ActionFactory->single('woocommerce_run...', Array, 1556534305, 'woocommerce-db-...') #3 /home/try2know/public_html/wp-content/plugins/woocommerce/includes/queue/class-wc-action-queue.php(44): as_schedule_single_action(1556534305, 'woocom in /home/try2know/public_html/wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_wpPostStore.php on line 33
    

    I tried reinstalling the woocommerce both via ftp and wordpress plugin manager. Can someone please help me?

    I recently migrated the site from a host to another. I think this issue happens because I installed woocommerce and restored the database using phpmyadmin. The backup file Ihave was taken in the old site when it was running a previos version of woocommerce.

Viewing 8 replies - 1 through 8 (of 8 total)
  • I’m having exactly the same problem using WooCommerce 3.6.2 and WordPress 5.1.1. Even with all plugins turned off (except WC) the problem persists.

    I’m having the same issue:

    I reinstalled the latest plugin but no luck.
    And also when i want to look into my products i get this message.

    2019-05-07T08:52:49+00:00 CRITICAL Uncaught exception ‘RuntimeException’ with message ‘Error saving action: Unable to save action.’ in /wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_wpPostStore.php:33
    Stack trace:
    #0 //wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_ActionFactory.php(109): ActionScheduler_wpPostStore->save_action(Object(ActionScheduler_Action))
    #1 //wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_ActionFactory.php(59): ActionScheduler_ActionFactory->store(Object(ActionScheduler_Action))
    #2 /wp-content/plugins/woocommerce/includes/libraries/action-scheduler/functions.php(18): ActionScheduler_ActionFactory->single(‘woocommerce_upd…’, Array, 1557219151, ”)
    #3 wp-content/plugins/woocommerce/includes/libraries/action-scheduler/classes/ActionScheduler_wpPostStore.php on line 33

    • This reply was modified 1 month, 2 weeks ago by  muizebelt.
    Moderator Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    @swah, @muizebelt, I believe you, but could you guys open a new thread each to discuss that? When creating your new thread you can say “I think X-Thread is having the same problem as me”. This helps us understand threads easier.

    Typical server timeout. You should not upgrade your database via the backend button. Espacially on shared hostings, or busy stores the risk of a timeout is high.
    Best practice would be upgrading woocommece and update the database via WP CLI

    It cannot be assumed that users of WooCommerce even know what WP CLI is. The database update should work under all circumstances, except misconfiguration or temporary outages.

    Shared servers are a fact of life for many people.

    Just check the github chanel of woocommerce and their wiki

    https://github.com/woocommerce/woocommerce/wiki/Upgrading-the-database-using-WP-CLI

    Doing upgrades via the command line is just best practice to avoid timeouts etc.

    @obscurant1st Some people were able to update the database by turning off the W3 Total Cache plugin. If this is your situation, try it

    Plugin Support dougaitken

    (@dougaitken)

    Automattic Happiness Engineer

    I’m going to lock this thread as it has gone quiet and slightly off topic.

    @braehler – updates via the Admin interface will run correctly if everything is playing together correctly.

    @swah @muizebelt @obscurant1st – if you’re still having issues and the database updated won’t run with only WooCommerce and the core Storefront theme active, then this means the issue is at a server level – speak to you host about overzealous caching or check to ensure the database user has delete permissions.

    In the past two weeks I’ve seen the database update fails for all those reasons:

    * Optimize-type plugins
    * Caching (either host or plugin)
    * Cron issues
    * Database user permissions errors

    If anyone is still having issue, please open your own thread or reach out to us at WooCommerce.com.

    Thanks,

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Fatal error when tyring to upgrade databsse’ is closed to new replies.