Re: [whatwg/fetch] Aborting fetch (#523)

jakearchibald commented on this pull request.



>  
- <li><p>Let <var>cancel</var> be an action that
- <a lt=terminated for=fetch>terminates</a> the ongoing fetch with reason
- <i>end-user abort</i>.
+ <li><p>Let <var>cancel</var> be an action that <a lt=terminated for=fetch>terminates</a> the
+ ongoing fetch with reason <i>fatal</i>.

Unless I'm reading things badly, XHR+fetch seems kinda broken as things stand.

Currently [`abort()`](https://xhr.spec.whatwg.org/#the-abort()-method) [terminates the request](https://xhr.spec.whatwg.org/#terminate-the-request) with reason *fatal*. Which surely means it won't [trigger the abort event](https://xhr.spec.whatwg.org/#handle-errors).

I think I'm going to have to PR XHR too ☹️.

The more I stare at it, the best way could be to remove termination reasons all together, and try and handle abort/timeout within XHR.

How does that sound?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/pull/523#discussion_r136062170

Received on Wednesday, 30 August 2017 13:12:42 UTC