WP-CLI and WooCommerce | WordPress.org

[ad_1]

Hello, I’m making a new topic to understand the matter well. First of all, great plugin! However, I encountered an issue with a WP-CLI command scheduled on cron jobs, that essentially calls a PHP script that updates prices and stocks from a CSV downloaded with cURL. The script returns the following error at the very beginning:

PHP Fatal error: Uncaught Error: Call to undefined function apcu_fetch() in /va r/www/html/wp-content/object-cache.php:224

I suppose the cache doesn’t work in the CLI, what is the best way to solve this? Should I modify php.ini to enable it, as I was reading around, change the name of the object-cache.php temporarily or something else? My concern here is I have lots of WooCommerce products and to say one, Docket Cache needs a bit of tweaking to work well, is this plugin the same? Should it be used with WooCommerce or it will cause wrong prices and stocks to be displayed, especially if I change the object-cache.php file name during script execution?

Bonus question: I use Redis on another website, should I have the same concerns with it/Memcached too?

Thank you

The page I need help with: [log in to see the link]

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer