Title: wp_cache_flush_runtime error
Last modified: April 9, 2023

---

# wp_cache_flush_runtime error

 *  Resolved [DaveWP196](https://wordpress.org/support/users/davewp196/)
 * (@davewp196)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/)
 * In the Action Scheduler there is an unguarded call to ‘wp_cache_flush_runtime’
   in ActionScheduler_QueueRunner::clear_caches() which results in a warning if 
   memory caching is not supported.
 * See [https://wordpress.org/support/topic/php-notice-function-wp_cache_flush_runtime-was-called-incorrectly/](https://wordpress.org/support/topic/php-notice-function-wp_cache_flush_runtime-was-called-incorrectly/)
   to more details of how to check to see if memory caching is supported.
 * Here is a possible solution:
 *     ```wp-block-code
       $memory_caching=(
          function_exists( 'wp_cache_flush_runtime' ) ?
              wp_cache_supports('flush_runtime') :
              false);
       if ( $memory_caching ) {
       ```
   

Viewing 6 replies - 1 through 6 (of 6 total)

 *  [Igor H](https://wordpress.org/support/users/ihereira/)
 * (@ihereira)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/#post-16641924)
 * Hi,
 * Thanks for sharing.
 * Kindly be advised that this forum is for inquiries related to WooCommerce Core.
   Is the solution above related to the plugin: [Memcached Object Cache](https://wordpress.org/plugins/memcached/)?
   If so, please create a thread in the corresponding forum here – [https://wordpress.org/support/plugin/memcached/#new-topic-0](https://wordpress.org/support/plugin/memcached/#new-topic-0).
 * Thank you very much!
 *  Thread Starter [DaveWP196](https://wordpress.org/support/users/davewp196/)
 * (@davewp196)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/#post-16642376)
 * Is ActionScheduler part of the WooCommerce core product suite as it is in the
   packages folder in WooCommerce? See [GitHub – woocommerce/action-scheduler: A scalable, traceable job queue for background processing large queues of tasks in WordPress. Specifically designed for distribution in WordPress plugins (and themes) – no server access required.](https://github.com/woocommerce/action-scheduler)
 * The code I reported an error is located in this generic module, and I merely 
   included a reference to the MemCached Object plugin to provide a bit more context
   to the report.
 *  [Saif](https://wordpress.org/support/users/babylon1999/)
 * (@babylon1999)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/#post-16645697)
 * Hello [@davewp196](https://wordpress.org/support/users/davewp196/),
 * Thank you so much for the suggested change.
 * If you believe something could be improved here, I kindly ask you to create a
   pull request for it on [GitHub](https://github.com/woocommerce/woocommerce).
 * Your contribution will be greatly appreciated. 😃
 * Cheers!
 *  [Igor H](https://wordpress.org/support/users/ihereira/)
 * (@ihereira)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/#post-16674062)
 * Hello,
 * We haven’t heard back from you in a while, so I’m going to mark this as resolved–
   we’ll be here if and/or when you are ready to continue.
   Thanks.
 *  Thread Starter [DaveWP196](https://wordpress.org/support/users/davewp196/)
 * (@davewp196)
 * [2 years, 12 months ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/#post-16818110)
 * The problem is not fixed in so far as every time you release a new version of
   WooCommerce, I keep finding the error is being reintroduced.
 * How do I ensure you integrate a version of the ActionScheduler into your code?
 *  [Saif](https://wordpress.org/support/users/babylon1999/)
 * (@babylon1999)
 * [2 years, 11 months ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/#post-16837910)
 * Hello [@davewp196](https://wordpress.org/support/users/davewp196/),
 * > The problem is not fixed in so far as every time you release a new version 
   > of WooCommerce, I keep finding the error is being reintroduced.
 * Sorry, but I’m not sure if I get the full picture.
 * Where do you see the error? Can you replicate this issue on a fresh installation
   of WordPress/WooCommerce?
   Could you also share a copy of your site’s System Status?
   You can find it via WooCommerce > Status. Select “Get system report” and then“
   Copy for support”.  Once you’ve done that, paste it here in your response.Look
   forward to hearing back from you.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘wp_cache_flush_runtime error’ is closed to new replies.

 * ![](https://ps.w.org/woocommerce/assets/icon.svg?rev=3234504)
 * [WooCommerce](https://wordpress.org/plugins/woocommerce/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/woocommerce/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/woocommerce/)
 * [Active Topics](https://wordpress.org/support/plugin/woocommerce/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/woocommerce/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/woocommerce/reviews/)

 * 6 replies
 * 3 participants
 * Last reply from: [Saif](https://wordpress.org/support/users/babylon1999/)
 * Last activity: [2 years, 11 months ago](https://wordpress.org/support/topic/wp_cache_flush_runtime-error/#post-16837910)
 * Status: resolved