Install WooCommerce Got Critical Error

You can run into the problem “There Has Been a Critical Error on Your Website” after installing WooCommerce. Please follow these instructions to properly examine your issue.

Service FAQ Image 27

Debug

Open your source code via FTP access and adding the following code to the bottom of your wp-config file which is right before “/* That’s all, stop editing! Happy publishing. */”

				
					define('WP_DEBUG', false);
define('WP_DEBUG_LOG', true);
				
			
Service FAQ Image 28

Reload your website and check the debug log in wp-content/debug.log. If it shows as follow, kindly move to the next step

  1. Table ‘.wp_actionscheduler_actions’ doesn’t exist
  2. PHP Fatal error: Uncaught RuntimeException: Error saving action: Error saving action: Incorrect table name ” in /classes/migration/ActionScheduler_DBStoreMigrator.php:44

According to debug log, the problem comes from WooCommerce Action-scheduler. It seems like new tables are not getting created in the Database.

Service FAQ Image 29

How to fix this issue?

Option 1 – Cannot access WPAdmin anymore

Step 1 – Disable WooCommerce Plugin: Log into FTP and change the name of this folder: wp-content/plugins/woocommerce. For example, change to woocommerce-old

Service FAQ Image 30

Step 2 – Install Action-scheduler Plugin: Now you can access WPAdmin normally. Download, install and active this plugin: https://github.com/woocommerce/action-scheduler

Service FAQ Image 31

Step 3: Navigate to Tools > Action Scheduled and wait for the tool to fix the issue automatically (about 3-5 mins)

Or URL yourdomain/wp-admin/tools.php?page=action-scheduler

Service FAQ Image 32

Step 4: After done, refresh your website. Now you can rename your Woocommerce folder again (from woocommerce-old into woocommerce) and reactive it to use normally

Service FAQ Image 33

Option 2 – Still can access WPAdmin normally

Navigate to WooCommerce > Status > Scheduled Actions and wait for the tool to fix automatically. 

URL: yourdomain/wp-admin/admin.php?page=wc-status&tab=action-scheduler

Service FAQ Image 34

After done, refresh your website and turn off the debug log. To learn more about the debugging in WordPress, click here 

$55