XHR blob requests for webp content causes net :: ERR_FAILED
Reported by
vicapowe...@gmail.com,
Jun 9 2016
|
||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/50.0.2661.102 Safari/537.36 Example URL: Steps to reproduce the problem: 1. Copy and paste the following into a the browser var xhr = new window.XMLHttpRequest(); var url = 'https://www.gstatic.com/webp/gallery/1.webp'; xhr.open('GET', url); xhr.responseType = 'blob'; xhr.onload = function(event) { console.log(this); } xhr.send(); The following error is produced: VM120:8 GET https://www.gstatic.com/webp/gallery/1.webp net::ERR_FAILED What is the expected behavior? The request to succeed What went wrong? The request failed with error net:::ERR_FAILED Did this work before? N/A Chrome version: 51.0.2704.84 Channel: stable OS Version: Windows NT 6.3 Flash Version:
,
Jun 9 2016
fwiw, a work around it request an `arraybuffer` instead of a `blob`. var xhr = new window.XMLHttpRequest(); var url = 'https://www.gstatic.com/webp/gallery/1.webp'; xhr.open('GET', url); xhr.responseType = 'arraybuffer'; xhr.onload = function(event) { var blob = new Blob([this.response], {type: 'image/webp'}); var img = document.createElement('img'); img.src = window.URL.createObjectURL(blob); document.body.appendChild(img); } xhr.send();
,
Jun 9 2016
Apologies, but I'm not authorized to release the network details on this workstation.
,
Jun 9 2016
,
Jun 10 2016
Is there any output on the devtools console other than VM120:8 GET https://www.gstatic.com/webp/gallery/1.webp net::ERR_FAILED ? In my environment, running the script on the devtools console attached to https://www.gstatic.com/ works (i.e., xhr.response returns a blob).
,
Jun 10 2016
I'll check with an administrator if it's possible to pull a net-internals log for this. I also haven't been able to reproduce on my Macbook so seems windows specific.
,
Jun 10 2016
Doesn't reproduce on 53.0.2761.0 (Official Build) canary (64 bit) on Windows 7. No error seen. I also confirmed that it renders by creating an img element as the comment #2 did. It seems something is wrong in blob downloading path. var xhr = new window.XMLHttpRequest(); var url = 'https://www.gstatic.com/webp/gallery/1.webp'; xhr.open('GET', url); xhr.responseType = 'blob'; xhr.onload = function(event) { var img = document.createElement('img'); img.src = window.URL.createObjectURL(this.response); document.body.appendChild(img); } xhr.send();
,
Jun 10 2016
Thank you for providing more feedback. Adding requester "rsleevi@chromium.org" for another review and adding "Needs-Review" label for tracking. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Jun 10 2016
,
Jun 28 2016
The code on comment 7 works also on 51.0.2704.103 and 51.0.2704.106. vicapowell39@: Does this still reproduce on your Windows machine? Does the resource get loaded in any other way e.g. viewing the image, <img> element for the image, etc.?
,
Jul 25 2016
,
Aug 18 2016
|
||||||
►
Sign in to add a comment |
||||||
Comment 1 by rsleevi@chromium.org
, Jun 9 2016