Closed mrnmnew closed 3 years ago
Hi @mrnmnew,
Thank you for submitting the issue. However, you didn’t fill out the details of the bug report template that we ask for. Without these details, we can’t fully evaluate this issue. Please provide us with the information requested so we could take a look further.
Describe the bug A clear and concise description of what the bug is. Please be as descriptive as possible; issues lacking detail, or for any other reason than to report a bug, may be closed without action.
To Reproduce Steps to reproduce the behavior:
Screenshots If applicable, add screenshots to help explain your problem.
Expected behavior A clear and concise description of what you expected to happen.
Isolating the problem (mark completed items with an [x]):
WordPress Environment
From: Leif Singer notifications@github.com Sent: 21 January 2021 14:28 To: woocommerce/woocommerce woocommerce@noreply.github.com Cc: Mark Newton mark@ecats.co.uk; Mention mention@noreply.github.com Subject: Re: [woocommerce/woocommerce] Unable to run stock report in Woocommerce Reports (#28863)
Hi @mrnmnewhttps://github.com/mrnmnew,
Thank you for submitting the issue. However, you didn’t fill out the details of the bug report template that we ask for. Without these details, we can’t fully evaluate this issue. Please provide us with the information requested so we could take a look further.
Describe the bug A clear and concise description of what the bug is. Please be as descriptive as possible; issues lacking detail, or for any other reason than to report a bug, may be closed without action.
To Reproduce Steps to reproduce the behavior:
Screenshots If applicable, add screenshots to help explain your problem.
Expected behavior A clear and concise description of what you expected to happen. None of the three reports run and all show the same error.
Isolating the problem (mark completed items with an [x]):
WordPress Environment
`
WordPress address (URL): https://shop.orkneyarchaeologysociety.org.uk
Site address (URL): https://shop.orkneyarchaeologysociety.org.uk
WC Version: 4.9.1
REST API Version: ✔ 4.9.1
WC Blocks Version: ✔ 4.3.0
Action Scheduler Version: ✔ 3.1.6
WC Admin Version: ✔ 1.8.3
Log Directory Writable: ✔
WP Version: 5.6
WP Multisite: –
WP Memory Limit: 256 MB
WP Debug Mode: –
WP Cron: ✔
Language: en_GB
External object cache: –
Server Info: Apache
PHP Version: 7.2.34
PHP Post Max Size: 8 MB
PHP Time Limit: 30
PHP Max Input Vars: 1000
cURL Version: 7.72.0
OpenSSL/1.1.1h
SUHOSIN Installed: –
MySQL Version: 5.5.5-10.3.27-MariaDB
Max Upload Size: 2 MB
Default Timezone is UTC: ✔
fsockopen/cURL: ✔
SoapClient: ✔
DOMDocument: ✔
GZip: ✔
Multibyte String: ✔
Remote Post: ✔
Remote Get: ✔
WC Database Version: 4.9.1
WC Database Prefix: wpbt_
Total Database Size: 17.61MB
Database Data Size: 12.22MB
Database Index Size: 5.39MB
wpbt_woocommerce_sessions: Data: 0.18MB + Index: 0.01MB + Engine MyISAM
wpbt_woocommerce_api_keys: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_attribute_taxonomies: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_downloadable_product_permissions: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_order_items: Data: 0.04MB + Index: 0.02MB + Engine MyISAM
wpbt_woocommerce_order_itemmeta: Data: 0.25MB + Index: 0.20MB + Engine MyISAM
wpbt_woocommerce_tax_rates: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_woocommerce_tax_rate_locations: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_shipping_zones: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_shipping_zone_locations: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_shipping_zone_methods: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_payment_tokens: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_payment_tokenmeta: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_woocommerce_log: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_actionscheduler_actions: Data: 0.36MB + Index: 0.12MB + Engine MyISAM
wpbt_actionscheduler_claims: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_actionscheduler_groups: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_actionscheduler_logs: Data: 0.21MB + Index: 0.13MB + Engine MyISAM
wpbt_blc_filters: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_blc_instances: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_blc_links: Data: 0.01MB + Index: 0.01MB + Engine MyISAM
wpbt_blc_synch: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_commentmeta: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_comments: Data: 2.06MB + Index: 1.53MB + Engine MyISAM
wpbt_failed_jobs: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_links: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_mailchimp_carts: Data: 0.01MB + Index: 0.00MB + Engine MyISAM
wpbt_mailchimp_jobs: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_options: Data: 3.65MB + Index: 0.22MB + Engine MyISAM
wpbt_pmpro_discount_codes: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_pmpro_discount_codes_levels: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_pmpro_discount_codes_uses: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_pmpro_memberships_categories: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_pmpro_memberships_pages: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_pmpro_memberships_users: Data: 0.01MB + Index: 0.02MB + Engine MyISAM
wpbt_pmpro_membership_levelmeta: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_pmpro_membership_levels: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_pmpro_membership_ordermeta: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_pmpro_membership_orders: Data: 0.04MB + Index: 0.05MB + Engine MyISAM
wpbt_postmeta: Data: 1.79MB + Index: 0.88MB + Engine MyISAM
wpbt_posts: Data: 2.74MB + Index: 1.39MB + Engine MyISAM
wpbt_queue: Data: 0.01MB + Index: 0.00MB + Engine MyISAM
wpbt_sfa_abandoned_carts: Data: 0.07MB + Index: 0.00MB + Engine MyISAM
wpbt_termmeta: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_terms: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_term_relationships: Data: 0.15MB + Index: 0.28MB + Engine MyISAM
wpbt_term_taxonomy: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_usermeta: Data: 0.52MB + Index: 0.29MB + Engine MyISAM
wpbt_users: Data: 0.01MB + Index: 0.02MB + Engine MyISAM
wpbt_wc_admin_notes: Data: 0.01MB + Index: 0.00MB + Engine MyISAM
wpbt_wc_admin_note_actions: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_wc_category_lookup: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_wc_customer_lookup: Data: 0.03MB + Index: 0.03MB + Engine MyISAM
wpbt_wc_download_log: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_wc_order_coupon_lookup: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_wc_order_product_lookup: Data: 0.04MB + Index: 0.04MB + Engine MyISAM
wpbt_wc_order_stats: Data: 0.02MB + Index: 0.03MB + Engine MyISAM
wpbt_wc_order_tax_lookup: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_wc_product_meta_lookup: Data: 0.01MB + Index: 0.03MB + Engine MyISAM
wpbt_wc_reserved_stock: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
wpbt_wc_tax_rate_classes: Data: 0.00MB + Index: 0.01MB + Engine MyISAM
wpbt_wc_webhooks: Data: 0.00MB + Index: 0.00MB + Engine MyISAM
attachment: 256
custom_css: 1
hf_membership_plan: 1
hf_user_membership: 1
jetpack_migration: 2
jp_img_sitemap: 3
jp_sitemap: 3
jp_sitemap_master: 3
nav_menu_item: 15
page: 14
post: 2
product: 120
product_variation: 20
revision: 80
shop_order: 303
shop_order_refund: 4
wafs: 1
Secure connection (HTTPS): ✔
Hide errors from visitors: ✔
Akismet Anti-Spam: by Automattic – 4.1.8
Private Store for WooCommerce B2B & Wholesale by B2BKing: by WebWizards – 1.0.0
Broken Link Checker: by WPMU DEV – 1.11.15
PublishPress Capabilities: by PublishPress – 1.10.1
GDPR Cookie Consent: by WebToffee – 1.9.5
Flexible Checkout Fields: by WP Desk – 2.9.1
Free shipping notification WooCommerce Pro: by PI Websolution – 1.4.4
Google Analytics: by ShareThis – 2.4.1
Hide Admin Bar From Non-admins: by Stranger Studios – 1.0
Import Users from CSV: by Andrew Lima – 1.0.1
Jetpack by WordPress.com: by Automattic – 9.3.1
Mailchimp for WooCommerce: by Mailchimp – 2.5.0
Maintenance: by WebFactory Ltd – 3.99
Paid Memberships Pro: by Stranger Studios – 2.5.2
Paid Memberships Pro - Register Helper Add On: by Paid Memberships Pro – 1.7
Paid Memberships Pro - WooCommerce Add On: by Paid Memberships Pro – 1.7.1
Regenerate Thumbnails: by Alex Mills (Viper007Bond) – 3.1.4
Resize Image After Upload: by ShortPixel – 1.8.6
Smart Image Resize for WooCommerce: by Nabil Lemsieh – 1.4.6
UpdraftPlus - Backup/Restore: by UpdraftPlus.Com
DavidAnderson – 1.16.46
Velvet Blues Update URLs: by VelvetBlues.com – 3.2.10
Abandoned Cart Reports For WooCommerce: by Small Fish Analytics – 2.6.2
WooCommerce Free Shipping: by Plugin Territory – 4.7.0
Woo Donations: by Geek Web Solution – 1.5
WooCommerce Blocks: by Automattic – 4.3.0
WooCommerce Admin: by WooCommerce – 1.8.3
WooCommerce PayPal Checkout Gateway: by WooCommerce – 2.1.1
WooCommerce Royal Mail Shipping Calculator Pro: by WPRuby – 3.3.0
WooCommerce: by Automattic – 4.9.1
Elementor: by Elementor.com – 3.0.16
Paid Memberships Pro - Mailchimp Add On: by Stranger Studios – 2.3.1
WooCommerce Shipping & Tax: by Automattic – 1.25.5
API Enabled: –
Force SSL: –
Currency: GBP (£)
Currency Position: left
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: –
Shop base: #6 - /
Basket: #7 - /cart/
Checkout: #8 - /checkout/
My account: #9 - /my-account/
Terms and conditions: ❌ Page not set
Name: Storefront
Version: 3.3.0
Author URL: https://woocommerce.com/
Child Theme: ❌ – If you are modifying WooCommerce on a parent theme that you did not build
personally we recommend using a child theme. See: How to create a child theme
WooCommerce Support: ✔
Overrides: –
Complete: 781
Oldest: 2020-12-25 13:34:51 +0000
Newest: 2021-01-25 12:15:55 +0000
Pending: 3
Oldest: 2021-01-25 13:15:55 +0000
Newest: 2021-01-30 20:09:34 +0000
` — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/woocommerce/woocommerce/issues/28863#issuecomment-764679124, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ABPVA7X4DA6MFDHOB6OS4OTS3A2YDANCNFSM4WK2I4CQ.
@mrnmnew thanks for those details. I tried reproducing this issue with an empty site -- latest WordPress, WooCommerce 4.9.1 (just as yours) and no products. I then added a few products and added different levels of stock to them.
However, this all worked fine on my end. Do you have a few more details about the products and stock levels in your store that could help us get to the bottom of this?
Alternatively you might want to try reproducing the issue on a fresh testing site. That way you'd be able to share with us the exact steps to reproduce the issue.
It works fine on my other sites. Does this error message help?
An error of type E_ERROR was caused in line 81 of the file /home/orkneyar/public_html/shop/wp-content/plugins/woocommerce/includes/admin/reports/class-wc-report-stock.php. Error message: Uncaught Error: Call to a member function get_id() on string in /home/orkneyar/public_html/shop/wp-content/plugins/woocommerce/includes/admin/reports/class-wc-report-stock.php:81 Stack trace:
From: Leif Singer notifications@github.com Sent: 27 January 2021 11:54 To: woocommerce/woocommerce woocommerce@noreply.github.com Cc: Mark Newton mark@ecats.co.uk; Mention mention@noreply.github.com Subject: Re: [woocommerce/woocommerce] Unable to run stock report in Woocommerce Reports (#28863)
@mrnmnewhttps://github.com/mrnmnew thanks for those details. I tried reproducing this issue with an empty site -- latest WordPress, WooCommerce 4.9.1 (just as yours) and no products. I then added a few products and added different levels of stock to them.
However, this all worked fine on my end. Do you have a few more details about the products and stock levels in your store that could help us get to the bottom of this?
Alternatively you might want to try reproducing the issue on a fresh testing site. That way you'd be able to share with us the exact steps to reproduce the issue.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/woocommerce/woocommerce/issues/28863#issuecomment-768235282, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ABPVA7S4ZRG6BDLF3HMONXDS375GPANCNFSM4WK2I4CQ.
on another site I look after when I select 'most stocked' report I get a simular error
Hi @mrnmnew,
Thank you for your follow-up and for providing additional details. I am sorry for the delayed response here.
I tested this further as well using WooCommerce 5.3 beta and did not experience the issue.
It works fine on my other sites.
You noted that the issue is present for you only on some of the sites but not the others. It could be that one of the plugins you are using on the sites where the issue is present is causing the issue.
You shared your System Status Report above where I see that you have several plugins installed. Please test your site for plugins conflict. To do that, you’d need to deactivate all plugins except for WooCommerce. Then test again.
If the issue is resolved with the default theme (which is Storefront and I see you are using it) and all plugins deactivated, it means that one of your plugins. You will then need to enable it one by one and test every time you do that in order to figure out which plugin is causing the issue.
Please let us know how it goes.
As a part of this repository’s maintenance, this issue is being marked as stale due to inactivity. Please feel free to comment on it in case we missed something.
This issue was closed because it has been 14 days with no activity.
Can anyone help? When I try to run the stock level report it fails with a critical error and the log gives :
2021-01-20T14:56:16+00:00 CRITICAL Uncaught Error: Call to a member function get_id() on string in /home/orkneyar/public_html/shop/wp-content/plugins/woocommerce/includes/admin/reports/class-wc-report-stock.php:81 Stack trace:
0 /home/orkneyar/public_html/shop/wp-admin/includes/class-wp-list-table.php(1439): WC_Report_Stock->column_default(Object(stdClass), 'product')
1 /home/orkneyar/public_html/shop/wp-admin/includes/class-wp-list-table.php(1379): WP_List_Table->single_row_columns(Object(stdClass))
2 /home/orkneyar/public_html/shop/wp-admin/includes/class-wp-list-table.php(1366): WP_List_Table->single_row(Object(stdClass))
3 /home/orkneyar/public_html/shop/wp-admin/includes/class-wp-list-table.php(1351): WP_List_Table->display_rows()
4 /home/orkneyar/public_html/shop/wp-admin/includes/class-wp-list-table.php(1278): WP_List_Table->display_rows_or_placeholder()
5 /home/orkneyar/public_html/shop/wp-content/plugins/woocommerce/includes/admin/reports/class-wc-report-stock.php(68): WP_List_Table->display()
6 /home/orkneyar/public_html/shop/ in /home/orkneyar/public_html/shop/wp-content/plugins/woocommerce/includes/admin/reports/class-wc-report-stock.php on line 81