Commit c1e2270
authored
Handle HTTP errors when fetching revisions (#5234)
This PR adds exception handling to `_get_url_content` in `revisions.py`
to prevent the testcase detail page from crashing with a 500 error when
external requests to Gitiles (`chromium.googlesource.com`) fail with
HTTP errors (such as 429, 403, or 503). This was caused by Gitiles
throttling anonymous traffic due to an outage (see b/499989694 for
context). This fix allows the UI to degrade gracefully, displaying 'No
component revisions found' instead of crashing.1 parent ef4af5d commit c1e2270
2 files changed
Lines changed: 12 additions & 1 deletion
File tree
- src/clusterfuzz/_internal
- build_management
- tests/core/build_management
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
182 | 182 | | |
183 | 183 | | |
184 | 184 | | |
185 | | - | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
186 | 190 | | |
187 | 191 | | |
188 | 192 | | |
| |||
Lines changed: 7 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
177 | 177 | | |
178 | 178 | | |
179 | 179 | | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
180 | 187 | | |
181 | 188 | | |
182 | 189 | | |
| |||
0 commit comments