Fatal error in woocommerce when updating to PHP 8.0
-
Dear support team,
I am forced to update my wordpress site to PHP 8.0 by my provider.
Unfortunately I get a fatal error when doing this. All themes and plugins are up to date.
WordPress version: 6.1.1
Woocommerce Version: 7.4.1
PHP: 7.4Help is much appreciated, the error log is attached.
Thanks
CRITICAL Uncaught ValueError: Missing format specifier at end of string in /wp-content/plugins/woocommerce/includes/class-wc-post-types.php:234 Stack trace: #0 wp-content/plugins/woocommerce/includes/class-wc-post-types.php(234): sprintf('Alle %', 'Bewertungen') #1 /wp-includes/class-wp-hook.php(308): WC_Post_Types::register_taxonomies('') #2 /wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters(NULL, Array) #3 /wp-includes/plugin.php(517): WP_Hook->do_action(Array) #4 /wp-settings.php(617): do_action('init') #5 /wp-config.php(81): require_once('/homepages/33/d...') #6 /wp-load.php(50): require_once('/homepages/33/d...') #7 /wp-admin/admin-ajax.php(22): require_once('/homepages/33/d...') #8 {main} thrown in /wp-content/plugins/woocommerce/includes/class-wc-post-types.php in Zeile 234
-
Thanks for reaching out!
I understand that you received the error message above when you upgraded to PHP 8.0, correct?
Can you please try to upgrade to a higher version of PHP and see if this resolves the issue?
Otherwise, I’d like to understand your site properly, please share your System Status Report that you can find via
WooCommerce > Status
. SelectGet system report
and thenCopy for support
. Once you’ve done that, you can paste it into your reply here.You could copy and paste your reply here or paste it via https://gist.github.com/ and send the link here.
Thanks!
Hi @xue28 ,
thanks for you reply. The error occurs on every PHP version greater than 7.4.
Attached is the woocommerce status.
Thanks in advance
` ### WordPress Environment ### WC Version: 7.4.1 REST API Version: ? 7.4.1 WC Blocks Version: ? 9.4.4 Action Scheduler Version: ? 3.5.4 Log Directory Writable: ? WP Version: 6.1.1 WP Multisite: – WP Memory Limit: ? 40 MB - Wir empfehlen das PHP Speicher-Limit (memory_limit) auf mindestens 64 MB zu setzen. Siehe: PHP Speicher-Limit erh?hen WP Debug Mode: – WP Cron: ? Language: de_DE External object cache: – ### Server Environment ### Server Info: Apache PHP Version: 7.4.33 PHP Post Max Size: 6 MB PHP Time Limit: 30 PHP Max Input Vars: 1000 cURL Version: 7.64.0 OpenSSL/1.1.1n SUHOSIN Installed: – MySQL Version: 5.7.38-log Max Upload Size: 64 MB Default Timezone is UTC: ? fsockopen/cURL: ? SoapClient: ? DOMDocument: ? GZip: ? Multibyte String: ? Remote Post: ? Remote Get: ? ### Database ### WC Database Version: 7.4.1 WC Database Prefix: zcTbvRTN Datenbank-Gesamtgr??e: 117.56MB Datenbank-Datengr??e: 91.44MB Datenbank-Indexgr??e: 26.12MB zcTbvRTNwoocommerce_sessions: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwoocommerce_api_keys: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwoocommerce_attribute_taxonomies: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwoocommerce_downloadable_product_permissions: Daten: 0.02MB + Index: 0.06MB + Engine InnoDB zcTbvRTNwoocommerce_order_items: Daten: 0.08MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwoocommerce_order_itemmeta: Daten: 0.44MB + Index: 0.42MB + Engine InnoDB zcTbvRTNwoocommerce_tax_rates: Daten: 0.02MB + Index: 0.06MB + Engine InnoDB zcTbvRTNwoocommerce_tax_rate_locations: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwoocommerce_shipping_zones: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNwoocommerce_shipping_zone_locations: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwoocommerce_shipping_zone_methods: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNwoocommerce_payment_tokens: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwoocommerce_payment_tokenmeta: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwoocommerce_log: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNactionscheduler_actions: Daten: 1.41MB + Index: 1.36MB + Engine InnoDB zcTbvRTNactionscheduler_claims: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNactionscheduler_groups: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNactionscheduler_logs: Daten: 1.52MB + Index: 0.70MB + Engine InnoDB zcTbvRTNcommentmeta: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNcomments: Daten: 0.27MB + Index: 0.28MB + Engine InnoDB zcTbvRTNcsp3_subscribers: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNformcraft_3_files: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNformcraft_3_forms: Daten: 0.06MB + Index: 0.00MB + Engine InnoDB zcTbvRTNformcraft_3_progress: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNformcraft_3_submissions: Daten: 4.52MB + Index: 0.00MB + Engine InnoDB zcTbvRTNformcraft_3_views: Daten: 0.16MB + Index: 0.00MB + Engine InnoDB zcTbvRTNfusion_forms: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNfusion_form_entries: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNfusion_form_fields: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNfusion_form_submissions: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNlayerslider: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNlayerslider_revisions: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNlinks: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNnovalnet_aff_account_detail: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNnovalnet_aff_user_detail: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNnovalnet_callback_history: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNnovalnet_subscription_details: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNnovalnet_transaction_detail: Daten: 0.02MB + Index: 0.09MB + Engine InnoDB zcTbvRTNoptions: Daten: 11.33MB + Index: 0.22MB + Engine InnoDB zcTbvRTNpostmeta: Daten: 22.55MB + Index: 13.73MB + Engine InnoDB zcTbvRTNposts: Daten: 33.52MB + Index: 2.88MB + Engine InnoDB zcTbvRTNppress_coupons: Daten: 0.02MB + Index: 0.05MB + Engine InnoDB zcTbvRTNppress_customers: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNppress_forms: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNppress_formsmeta: Daten: 0.06MB + Index: 0.05MB + Engine InnoDB zcTbvRTNppress_meta_data: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNppress_ordermeta: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNppress_orders: Daten: 0.02MB + Index: 0.13MB + Engine InnoDB zcTbvRTNppress_plans: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNppress_sessions: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNppress_subscriptions: Daten: 0.02MB + Index: 0.09MB + Engine InnoDB zcTbvRTNpum_subscribers: Daten: 0.02MB + Index: 0.06MB + Engine InnoDB zcTbvRTNrevslider_css: Daten: 0.14MB + Index: 0.02MB + Engine InnoDB zcTbvRTNrevslider_css_bkp: Daten: 0.16MB + Index: 0.00MB + Engine InnoDB zcTbvRTNrevslider_layer_animations: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNrevslider_layer_animations_bkp: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNrevslider_navigations: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNrevslider_navigations_bkp: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNrevslider_sliders: Daten: 0.11MB + Index: 0.02MB + Engine InnoDB zcTbvRTNrevslider_sliders_bkp: Daten: 0.11MB + Index: 0.00MB + Engine InnoDB zcTbvRTNrevslider_slides: Daten: 0.30MB + Index: 0.02MB + Engine InnoDB zcTbvRTNrevslider_slides_bkp: Daten: 0.45MB + Index: 0.00MB + Engine InnoDB zcTbvRTNrevslider_static_slides: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNrevslider_static_slides_bkp: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNsbi_feeds: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNsbi_feed_caches: Daten: 0.16MB + Index: 0.02MB + Engine InnoDB zcTbvRTNsbi_instagram_feeds_posts: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNsbi_instagram_feed_locator: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNsbi_instagram_posts: Daten: 0.09MB + Index: 0.00MB + Engine InnoDB zcTbvRTNsbi_sources: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNtermmeta: Daten: 0.08MB + Index: 0.03MB + Engine InnoDB zcTbvRTNterms: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNterm_relationships: Daten: 1.52MB + Index: 0.48MB + Engine InnoDB zcTbvRTNterm_taxonomy: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNusermeta: Daten: 1.52MB + Index: 0.45MB + Engine InnoDB zcTbvRTNusers: Daten: 0.06MB + Index: 0.05MB + Engine InnoDB zcTbvRTNwc_admin_notes: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNwc_admin_note_actions: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwc_category_lookup: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNwc_customer_lookup: Daten: 0.05MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwc_download_log: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwc_order_coupon_lookup: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwc_order_product_lookup: Daten: 0.06MB + Index: 0.06MB + Engine InnoDB zcTbvRTNwc_order_stats: Daten: 0.05MB + Index: 0.05MB + Engine InnoDB zcTbvRTNwc_order_tax_lookup: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNwc_product_attributes_lookup: Daten: 0.09MB + Index: 0.06MB + Engine InnoDB zcTbvRTNwc_product_download_directories: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwc_product_meta_lookup: Daten: 1.52MB + Index: 0.95MB + Engine InnoDB zcTbvRTNwc_rate_limits: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwc_reserved_stock: Daten: 0.02MB + Index: 0.00MB + Engine InnoDB zcTbvRTNwc_tax_rate_classes: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNwc_webhooks: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNyoast_indexable: Daten: 7.28MB + Index: 2.50MB + Engine InnoDB zcTbvRTNyoast_indexable_hierarchy: Daten: 0.09MB + Index: 0.14MB + Engine InnoDB zcTbvRTNyoast_migrations: Daten: 0.02MB + Index: 0.02MB + Engine InnoDB zcTbvRTNyoast_primary_term: Daten: 0.02MB + Index: 0.03MB + Engine InnoDB zcTbvRTNyoast_seo_links: Daten: 0.05MB + Index: 0.03MB + Engine InnoDB zcTbvRTNyoast_seo_meta: Daten: 0.33MB + Index: 0.00MB + Engine InnoDB ### Post Type Counts ### amn_mi-lite: 3 attachment: 1211 custom_css: 1 customize_changeset: 3 fusion_element: 3 fusion_template: 1 nav_menu_item: 17 oembed_cache: 1 page: 22 popup_theme: 11 post: 12 product: 57 product_variation: 1242 revision: 1611 seedprod: 2 shop_coupon: 2 shop_order: 274 shop_order_refund: 9 slide: 19 themefusion_elastic: 2 ### Security ### Secure connection (HTTPS): ? Hide errors from visitors: ? ### Active Plugins (17) ### FormCraft MyMail Add-On: von nCrafts – 1.0.1 All 404 Redirect to Homepage: von wp-buy – 4.2 Cookie Notice & Compliance for GDPR / CCPA: von Hu-manity.co – 2.4.7 DHL Shipping Germany for WooCommerce: von DHL – 3.3.0 FormCraft reCaptcha Add-On: von nCrafts – 1.8 FormCraft: von nCrafts – 3.8.12 Avada Builder: von ThemeFusion – 3.9.2 Avada Core: von ThemeFusion – 5.9.2 Google Analytics for WordPress by MonsterInsights: von MonsterInsights – 8.12.1 Google Analytics Opt-Out: von WP-Buddy – 2.3.5 Smash Balloon Instagram Feed: von Smash Balloon – 6.1.2 Loco Translate: von Tim Whitlock – 2.6.3 FormCraft MailChimp Add-On: von nCrafts – 1.8 My Custom Functions: von Space X-Chimp – 4.51 Slider Revolution: von ThemePunch – 6.6.11 Payment Plugins for Stripe WooCommerce: von Payment Plugins [email protected] – 3.3.38 WooCommerce: von Automattic – 7.4.1 ### Inactive Plugins (10) ### Akismet Anti-Spam: von Automattic – 5.0.2 Booster for WooCommerce: von Pluggabl LLC – 6.0.4 Coming Soon Page, Maintenance Mode, Landing Pages & WordPress Website Builder by SeedProd: von SeedProd – 6.15.7 Customizer for WooCommerce: von SkyVerge – 2.7.7 PW WooCommerce Bulk Edit: von Pimwick LLC – 2.111 Redirector: von Ralf Hortt – 3.0.1 W3 Total Cache: von BoldGrid – 2.3.0 WooCommerce Product Image Flipper: von jameskoster – 0.4.2 WooCommerce Remove Product Sorting: von SkyVerge – 1.0.0 Yoast SEO: von Team Yoast – 20.2.1 ### Must Use Plugins (1) ### 1&1 Product Subdomain: von 1&1 – 1.0.1 ### Settings ### API Enabled: ? Force SSL: – Currency: EUR (€) Currency Position: right_space Thousand Separator: . Decimal Separator: , Number of Decimals: 2 Taxonomies: Product Types: external (external) grouped (grouped) simple (simple) variable (variable) Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog) exclude-from-search (exclude-from-search) featured (featured) outofstock (outofstock) rated-1 (rated-1) rated-2 (rated-2) rated-3 (rated-3) rated-4 (rated-4) rated-5 (rated-5) Connected to WooCommerce.com: ? Enforce Approved Product Download Directories: – Order datastore: WC_Order_Data_Store_CPT ### WC Pages ### Shop-Basis: #10888 - /shop/ Warenkorb: #12456 - /warenkorb/ Kasse: #12935 - /checkout/ Mein Konto: #12938 - /mein-konto/ Allgemeine Gesch?ftsbedingungen: #13348 - /agb/ ### Theme ### Name: Avada Child Version: 1.0.0 Author URL: https://theme-fusion.com Child Theme: ? Parent Theme Name: Avada Parent Theme Version: 7.9.2 Parent Theme Author URL: https://themeforest.net/user/ThemeFusion WooCommerce Support: ? ### Templates ### Overrides: Avada/woocommerce/cart/cart.php Avada/woocommerce/checkout/form-pay.php Avada/woocommerce/checkout/review-order.php Avada/woocommerce/checkout/thankyou.php Avada/woocommerce/loop/loop-start.php Avada/woocommerce/single-product/add-to-cart/variable.php Avada/woocommerce/single-product/short-description.php Avada/woocommerce/single-product/tabs/additional-information.php Avada/woocommerce/single-product/tabs/description.php ### Admin ### Enabled Features: activity-panels analytics coupons customer-effort-score-tracks import-products-task experimental-fashion-sample-products shipping-smart-defaults shipping-setting-tour homescreen marketing multichannel-marketing mobile-app-banner navigation new-product-management-experience onboarding onboarding-tasks remote-inbox-notifications remote-free-extensions payment-gateway-suggestions shipping-label-banner subscriptions store-alerts transient-notices woo-mobile-welcome wc-pay-promotion wc-pay-welcome-page Disabled Features: minified-js product-variation-management settings Daily Cron: ? Next scheduled: 2023-03-06 22:24:34 +01:00 Options: ? Notes: 21 Onboarding: completed ### Action Scheduler ### Fertiggestellt: 133 Oldest: 2023-02-04 09:16:36 +0100 Newest: 2023-03-06 19:29:33 +0100 Fehlgeschlagen: 1 Oldest: 2023-03-04 19:02:59 +0100 Newest: 2023-03-04 19:02:59 +0100 Ausstehend: 2 Oldest: 2023-03-07 11:05:41 +0100 Newest: 2023-03-07 19:29:33 +0100 ### Status report information ### Generated at: 2023-03-06 19:36:35 +01:00 `
Hello @luckystrike71,
Thank you for sharing the report!
Although this is not related to the problem, I can see your server’s memory is lower than recommended by WooCommerce, please consider upgrading it in the future.
As for the error, seems like it has to do with a wrong translation, this was previously reported here.
Since you’re using Loco Translate, I recommend you start by updating the.po
file. If that doesn’t work, you manually try translating the mentioned string toAlle %s
.
Let us know how it goes!Hi, I have checked the wrong translation before and that does not solve the issue. The
Alle %s
error was not there I have doublechecked manually. What else can be the reason?-
This reply was modified 2 years ago by
luckystrike71.
Hi @luckystrike71 ,
Thanks for providing an update!
Just to clarify, does this issue occur when the Loco Translate plugin is deactivated?
If you are unsure, as a next step, please could you deactivate the Loco Translate plugin and see if the error is still present.
If the error is still present, can you try deleting Loco Translate and ensure that all translation files have been removed, and then check see if this makes any difference?
If this still makes no difference, I’d suggest performing a full conflict test to rule out any theme/plugin conflicts which may be causing the error.
To test, you’ll first want to change the theme on your site to Storefront, then check to see if the issue is still present. If that resolves the issue, you’ll want to get in touch with your theme’s developer and see if they have an update or fix for you.
If changing the theme doesn’t help, you’ll want to deactivate all plugins except for WooCommerce and take a look. If that fixes the problem, re-enable the other plugins one by one (gradually), checking after each, to see where the issue is coming from.
If you do not want to test this on your live site, you can clone your site to a staging environment and perform tests without modifying your live site or impacting customers. This is possible to do it using the free WP Staging plugin.
Let us know how this goes!
Hi @luckystrike71 ,
We haven’t heard back from you in a while, so I’m going to mark this as resolved – we’ll be here if you need any further help with this.
Cheers!
-
This reply was modified 2 years ago by
- The topic ‘Fatal error in woocommerce when updating to PHP 8.0’ is closed to new replies.