hypothesis / hypothesis/client
Improve handling of network errors when making API requests
- Dominant language
- Mustache
- Stars
- 730
- Forks
- 224
- PR merge metrics
- No merged PRs in 30d
Description
Since the recent changes to inter-frame communication in the client the volume of noise in Sentry had now dropped to manageable levels, to the point that we could soon consider turning on internal notifications of new reports again.
Looking at the [current reports](https://sentry.io/organizations/hypothesis/issues/?project=69811&query=is%3Aunresolved) for the client project in Sentry, most of the remaining issues are transient network problems. These include:
- 5xx responses from some service in between the client and the backend
- Canceled network requests (I think that's what [this Sentry issue](https://sentry.io/organizations/hypothesis/issues/1205785027/?project=69811&query=is%3Aunresolved) is)
- 200 responses that are expected to have a JSON body but which actually have an empty or invalid body. See [this issue](https://sentry.io/organizations/hypothesis/issues/1274716662/?project=69811&query=is%3Aunresolved) and also [error suppressions in the Sentry config](https://github.com/hypothesis/client/blob/6642f90c4f598547253b021ca254703bb64754a6/src/sidebar/util/sentry.js#L64)
We should look into either improving how these are handled or suppressing the exception if there isn't anything useful we can do about them. The hypothesized issue with "successful" responses that have empty JSON bodies needs to be verified in different browsers to confirm that these are the cause of the problem.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.