woocommerce / woocommerce-android

WooCommerce Android app
https://www.woocommerce.com/mobile
GNU General Public License v2.0
277 stars 135 forks source link

Track errors when failing to load content from Blaze dsp #12878

Closed JorgeMucientes closed 1 week ago

JorgeMucientes commented 2 weeks ago

We noticed when there are Jetpack sync issues, Blaze feature is impacted and the campaign creation flow will fail. Request such loading ad /suggestions will return errors like:

{"message":"Unexpected Server Error","errorMessage":"Request failed with status code 404","stack":["AxiosError: Request failed with status code 404","    at settle (\/app\/dsp\/node_modules\/axios\/lib\/core\/settle.js:19:12)","    at BrotliDecompress.handleStreamEnd (\/app\/dsp\/node_modules\/axios\/lib\/adapters\/http.js:585:11)","    at BrotliDecompress.emit (node:events:529:35)","    at endReadableNT (node:internal\/streams\/readable:1400:12)","    at processTicksAndRejections (node:internal\/process\/task_queues:82:21)"]}

Add tracking to this type of errors to monitor how often they happen. Currently we are on the dark with this. We had a couple discussion but could not figure out what caused the sync issues, so let's try to figure out if this is something users are experiencing or if its only devs on their test sites experiencing this.

New Event: _blaze_suggestions_loading_failed Property: error_type | $errorMessageValue

Equivalent issue on iOS: https://github.com/woocommerce/woocommerce-ios/issues/14337

dangermattic commented 2 weeks ago

🚫 Please add a type label (e.g. type: enhancement) and a feature label (e.g. feature: stats) to this issue.