Support » Plugin: WooCommerce » On WooCommerce 3.0 getting Fatal error: Uncaught Exception: Invalid order.

  • Resolved Ahmed Ehsaan

    (@wpeshaan)


    Fatal error: Uncaught Exception: Invalid order. in /home/appleme/public_html/wp-content/plugins/woocommerce/includes/data-stores/abstract-wc-order-data-store-cpt.php:86Stack trace: #0 /home/appleme/public_html/wp-content/plugins/woocommerce/includes/class-wc-data-store.php(143): Abstract_WC_Order_Data_Store_CPT->read(Object(WC_Order)) #1 /home/appleme/public_html/wp-content/plugins/woocommerce/includes/abstracts/abstract-wc-order.php(109): WC_Data_Store->read(Object(WC_Order)) #2 /home/appleme/public_html/wp-content/plugins/woo-shipment-tracking-order-tracking/includes/class-wf-tracking-admin.php(280): WC_Abstract_Order->__construct(5195) #3 /home/appleme/public_html/wp-content/plugins/woo-shipment-tracking-order-tracking/includes/class-wf-tracking-admin.php(149): WF_Tracking_Admin->wf_load_order(5195) #4 /home/appleme/public_html/wp-includes/class-wp-hook.php(300): WF_Tracking_Admin->wf_add_tracking_metabox(‘post’) #5 /home/appleme/public_html/wp-includes/class-wp-hook.php(323): WP_Hook->apply_filters(NULL, Array) #6 /h in /home/appleme/public_html/wp-content/plugins/woocommerce/includes/data-stores/abstract-wc-order-data-store-cpt.php on line 86

Viewing 11 replies - 1 through 11 (of 11 total)
  • I get this error when posting a new blog. Check here: https://www.useloom.com/share/7e70fded094242148fa805b864bf3534

    It’s WooCommerce Shipment Tracking Basic plugin creating conflict with WooCommerce 3.0

    how do you fix it ?

    Plugin Support Rynald0s

    (@rynald0s)

    Automattic Happiness Engineer

    I’m getting this error as well. Hoping to find a solution soon.

    Same error here.

    Fatal error: Uncaught exception 'Exception' with message 'Invalid product.' in /srv/bindings/fbd32283283e4c91b6dcb3aa089029e3/code/wp-content/plugins/woocommerce/includes/data-stores/class-wc-product-data-store-cpt.php:133 Stack trace: #0 /srv/bindings/fbd32283283e4c91b6dcb3aa089029e3/code/wp-content/plugins/woocommerce/includes/class-wc-data-store.php(143): WC_Product_Data_Store_CPT->read(Object(WC_Product)) #1 /srv/bindings/fbd32283283e4c91b6dcb3aa089029e3/code/wp-content/plugins/woocommerce/includes/abstracts/abstract-wc-product.php(126): WC_Data_Store->read(Object(WC_Product)) #2 /srv/bindings/fbd32283283e4c91b6dcb3aa089029e3/code/wp-content/plugins/woocommerce-product-stock-alert/classes/class-woo-product-stock-alert-admin.php(230): WC_Product->__construct(4509) #3 [internal function]: WOO_Product_Stock_Alert_Admin->check_product_stock_status(4509, Object(WP_Post)) #4 /srv/bindings/fbd32283283e4c91b6dcb3aa089029e3/code/wp-includes/class-wp-hook.php(300): call_user_func_array(Array, Array) #5 /srv/bindings/fbd32283283 in /srv/bindings/fbd32283283e4c91b6dcb3aa089029e3/code/wp-content/plugins/woocommerce/includes/data-stores/class-wc-product-data-store-cpt.php on line 133

    Digging further noticed the plugin https://wordpress.org/plugins/woocommerce-product-stock-alert/ is causing the issue. Deactivating it will fix the error. Updated the thread: https://wordpress.org/support/topic/plugin-no-longer-working-after-woocommerce-update

    • This reply was modified 2 years, 2 months ago by  ravimallya.

    Hello,
    this is probably not a plugin error.
    I fixed it adding

    return false;

    to public function read at line 89 of includes/data-stores/abstract-wc-order-data-store-cpt.php, before the exception.

    It was removed in v 3.0.0.
    Probably not the right way to fix it, but now it’s working.
    Good luck.

    Hey alinuxit,

    Could you please let me know where did you edited the file exactly?

    I didnt find the line and where i should write that returne false,

    Thanks,
    Laszlo

    Here we are!

    In that file, inside function “read”, inside the first “if”, just before the exception.

    Hope this can help you.

    I have updated all of the plug-ins and still getting the error message:

    Fatal error: Uncaught exception ‘Exception’ with message ‘Invalid order.’ in /homepages/8/d617609289/htdocs/public_html/wp-content/plugins/woocommerce/includes/data-stores/abstract-wc-order-data-store-cpt.php:89 Stack trace: #0 /homepages/8/d617609289/htdocs/public_html/wp-content/plugins/woocommerce/includes/class-wc-data-store.php(147): Abstract_WC_Order_Data_Store_CPT->read(Object(WC_Order)) #1 /homepages/8/d617609289/htdocs/public_html/wp-content/plugins/woocommerce/includes/abstracts/abstract-wc-order.php(109): WC_Data_Store->read(Object(WC_Order)) #2 /homepages/8/d617609289/htdocs/public_html/wp-content/plugins/ups-woocommerce-shipping/includes/class-wf-shipping-ups-tracking.php(38): WC_Abstract_Order->__construct(‘2438’) #3 /homepages/8/d617609289/htdocs/public_html/wp-content/plugins/ups-woocommerce-shipping/includes/class-wf-shipping-ups-tracking.php(179): WF_Shipping_UPS_Tracking->wf_load_order(‘2438’) #4 [internal function]: WF_Shipping_UPS_Tracking->wf_add_admin_metabox(‘product’) #5 /homepages/8/d617609289/ht in /homepages/8/d617609289/htdocs/public_html/wp-content/plugins/woocommerce/includes/data-stores/abstract-wc-order-data-store-cpt.php on line 89

    add return false; after 135
    wp-content/plugins/woocommerce/includes/data-stores/class-wc-product-data-store-cpt.php

    • This reply was modified 1 year, 5 months ago by  hossainshakil.
    • This reply was modified 1 year, 5 months ago by  hossainshakil.
Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘On WooCommerce 3.0 getting Fatal error: Uncaught Exception: Invalid order.’ is closed to new replies.