Method
wrap_errors
(request: APIRequest, call_next: CallNext)
Source from the content-addressed store, hash-verified
| 832 | ) |
| 833 | |
| 834 | def wrap_errors(request: APIRequest, call_next: CallNext) -> Any: |
| 835 | try: |
| 836 | return call_next(request) |
| 837 | except APIConnectionError as err: |
| 838 | # wrapping a retryable failure with `raise ... from` keeps it on the retry path |
| 839 | raise Boom("wrapped") from err |
| 840 | |
| 841 | client = make_sync_client(middleware=[wrap_errors], max_retries=2) |
| 842 | |
Callers
nothing calls this directly
Tested by
no test coverage detected