CodSpeedHQ / runner

The CodSpeed runner, gathering performance data from CI environments
https://codspeed.io
Apache License 2.0
2 stars 2 forks source link

fix(uploader): handle error response when retrieving upload data #11

Closed adriencaccia closed 6 months ago

adriencaccia commented 6 months ago

When there is a client error during the retrieval of the upload data, the error is obfuscated. This prevents users from seeing helpful error messages to debug the problem.

See https://github.com/unjs/magic-regexp/actions/runs/7280511804/job/19839080023?pr=363#step:6:73 as an example

This PR ensures that when a client error is detected, it is returned to the user.

For example, Failed to retrieve upload data: 401 Unauthorized {"error":"Repository not found (or the token is invalid)"}