Fix hooks receiving an aborted `signal` after retrying a timeout
Before adoption: this commit came in with the history the project adopted, so no landing records it.
The abort controller was only replaced right before the next fetch, so `beforeRetry` ran with the signal that the timeout had already aborted. The replacement also bypassed the request assignment helper, leaving the cached normalized options pointing at the old signal for `afterResponse` and `beforeError`. The reset now happens before the `beforeRetry` hooks and goes through the assignment helper, so every hook sees the signal that the retry actually uses.
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
2 files+90 added−8 removed
- tests:+83 added−0 removed
- other:+7 added−8 removed