-
Notifications
You must be signed in to change notification settings - Fork 27.1k
HttpClient fails to parse an empty 200 response in IE11 #18680
Copy link
Copy link
Closed
Labels
area: common/httpIssues related to HTTP and HTTP ClientIssues related to HTTP and HTTP Clientfreq1: lowtype: bug/fix
Description
I'm submitting a...
[ ] Regression (a behavior that used to work and stopped working in a new release)
[x] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question
Current behavior
The HttpClient throws an error "Http failure during parsing for ..." in the case of an empty 200 response in IE11.
The issue is not reproducible in Chrome and Firefox.
Setting a responseType option to "text" helps to resolve the issue.
Expected behavior
IE11 returns null by analogue with other browsers.
Minimal reproduction of the problem with instructions
Make an HttpClient.get request to an endpoint with the an empty file in IE11.
See this plunker for an example.
What is the motivation / use case for changing the behavior?
It is expected to have a consistent behavior across all browsers.
Environment
Angular version: 4.3.4
Browser:
- Chrome (desktop) version XX
- Chrome (Android) version XX
- Chrome (iOS) version XX
- Firefox version XX
- Safari (desktop) version XX
- Safari (iOS) version XX
- IE version 11
- Edge version XX
For Tooling issues:
- Node version: 6.10
- Platform: Windows
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area: common/httpIssues related to HTTP and HTTP ClientIssues related to HTTP and HTTP Clientfreq1: lowtype: bug/fix