Commit 6a60754
authored
## Problem
The generic `API request failed: 404 Not Found` from `apiRequest()`
doesn't identify which endpoint failed. This affects **24 users**
([CLI-BS](https://sentry.sentry.io/issues/7316293255/)) across issue
view, whoami, and log list commands.
## Fix
Two changes:
1. **Pass endpoint to ApiError** in `apiRequest()` so it's captured in
telemetry
2. **Show endpoint in `ApiError.format()`** so users see which API path
failed:
```
API request failed: 404 Not Found
Endpoint: /auth/
{"detail": "Not found."}
```
This helps users identify:
- Self-hosted endpoints that don't exist (e.g., `/auth/` on older
instances)
- Wrong org/project context causing resource-not-found
- Missing features (e.g., logs endpoint not enabled)
1 parent 8236325 commit 6a60754
2 files changed
+5
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
296 | 296 | | |
297 | 297 | | |
298 | 298 | | |
299 | | - | |
| 299 | + | |
| 300 | + | |
300 | 301 | | |
301 | 302 | | |
302 | 303 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
64 | 67 | | |
65 | 68 | | |
66 | 69 | | |
| |||
0 commit comments