• Resolved siutek

    (@siutek)


    Hi,
    I have a store that is displaying a critical error:

    PHP Fatal error: Uncaught Error: Call to undefined method AutomatticWooCommerce\Blocks\AIContent\PatternsHelper::get_image_url(). WordPress is version 6.7.2, Woocommerce is version 9.9.4. I’ve tried removing the WC plugin completely and uploading a brand new one via FTP, version 10.0.2 – but the error returns.

    Interestingly, I have another site where I have WC version 9.9.4 and there everything works fine.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi @siutek,

    Thanks for sharing those details!

    The error you’re seeing is related to the PatternsHelper class in WooCommerce Blocks. That class is currently empty and deprecated—it exists only to avoid breaking references, but it doesn’t include any usable methods like get_image_url(). If any code on your site tries to call that method, it will trigger a fatal error.

    This usually happens if a theme or plugin is making a call to that method, expecting it to exist. Since it doesn’t, the site crashes.

    To resolve this, I recommend checking your active theme and any custom plugins for references to PatternsHelper::get_image_url(). If found, removing or adjusting that code should fix the issue.

    Thank you.

    Thread Starter siutek

    (@siutek)

    Hi,
    I installed and ran the latest storefront theme, disabled all plugins. I don’t have any caching mechanism. When I enable woocommerce plugin, I get this error. I have no idea where it could be coming from. I have nothing that could generate it, everything is disconnected.
    WordPress is also in the latest version.

    Hi @siutek,

    Thanks again for the update. Since the fatal error persists even with Storefront active and all plugins disabled, there might still be some leftover code, server-side cache, or a hidden script causing it.

    To help narrow this down, here are a few steps that would be helpful:

    First, please share your WooCommerce System Status Report. You can get a System Status Report by going to WooCommerce > Status > Get system report, then paste it into https://pastebin.com or https://gist.github.com

    Next, please try reinstalling WooCommerce completely. Sometimes, even after deleting and reinstalling, some old files can remain in the plugin folder. To be sure:

    1. Deactivate WooCommerce from your Plugins screen
    2. Connect via FTP or File Manager and delete the entire wp-content/plugins/woocommerce folder
    3. Then reinstall WooCommerce either by uploading a fresh ZIP or installing from the dashboard

    If the issue still happens, enabling debug logging can help identify where the deprecated method call is coming from. 

    Install the WP Debugging plugin from the WordPress plugin directory. It will automatically turn on logging.

    Then try activating WooCommerce again. A debug log will be generated at wp-content/debug.log. This file should show which file or line is trying to use the PatternsHelper::get_image_url() method.

    Let us know what you find in the log, and we’ll help you take the next steps.

    • This reply was modified 10 months, 1 week ago by Sai (woo-hc).
    Plugin Support Chris Moreira – a11n

    (@chrism245)

    We noticed that we haven’t received a reply from you for some time, so I’ll mark this thread as resolved. If you need more help, please start a new thread.

    If you have a few minutes, we’d love if you could leave us a review: https://ww.wp.xz.cn/support/plugin/woocommerce/reviews/

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

The topic ‘Fatal error – PatternsHelper::get_image_url()’ is closed to new replies.