Sentry-cli: Improve `error: API request failed`

Created on 27 Nov 2018  路  8Comments  路  Source: getsentry/sentry-cli

OS:

  • [ ] Windows
  • [x] MacOS
  • [ ] Linux

_Platform:_

  • [ ] iOS
  • [x] Android

I have following issue:

Uploading sourcemaps for release {witheld}
> Uploading source maps for release {witheld}
error: API request failed
  caused by: [55] Failed sending data to the peer
:app:bundleReleaseJsAndAssets FAILED

Steps to reproduce:

  1. Have a poor internet connection, VPN, or live in a 3rd world country.
  2. $ android/gradlew assembleRelease -p android/

Actual result:
I get API request failed.

Expected result:

API request failed does not clearly define what exactly the issue is.

If I am on a VPN (or perhaps I updated my host file) that uses Pi-hole, the sentry domain name can be blocked, thus not allowing me to connect.

I want to know if the API request failed b/c

  • its trying to connect to the ip: 0.0.0.0 (Pi-hole blocked b/c VPN provider)
  • Sentry API is down (timeout?)
  • My ISP / wifi is bad and the connection got dropped halfway through the upload

If the error could include:

  • domain name we are trying to connect to
  • the ip address we are trying to connect to
  • better transparency about progress (what percentage has uploaded so far)
  • HTTP status code of the failure if one exists
  • Say if there was a timeout

Nice to have:
It would be super cool if the cli could connect to https://status.sentry.io/ and automatically tell me if there are known issues.

I am able to use Activity Monitor's "Network" tab to monitor the network activity of the cli tool. In my current case, it seems like its just my wifi is dropping too many packets since the tool is able to upload some information.

releases enhancement

Most helpful comment

facing the same issue.

All 8 comments

facing the same issue.

I have the same issue on iOS but happens almost randomly. :/

Same issue for iOS, any update?

It has been 1.5 years since I posted this :-/ I guess this company needs free labor from open source devs to support their products...

Really struggling with this.

Same issue here on android

In order to even start debugging this, I need any sort of logs, preferably with debug log level (SENTRY_LOG_LEVEL=debug or --log-level=debug). And reproducible example. Thanks

Closing the issue as a part of large repository cleanup, due to it being inactive and/or outdated.
Please do not hesitate to ping me if it is still relevant, and I will happily reopen and work on it.
Cheers!

Was this page helpful?
0 / 5 - 0 ratings