Bug 196174 - XMLHttpRequestUpload's loadstart event not correctly initialized
Summary: XMLHttpRequestUpload's loadstart event not correctly initialized
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-03-23 02:02 PDT by Anne van Kesteren
Modified: 2019-04-02 16:00 PDT (History)
10 users (show)

See Also:


Attachments
Patch (15.51 KB, patch)
2019-03-26 15:13 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews103 for mac-highsierra (2.45 MB, application/zip)
2019-03-26 16:17 PDT, Build Bot
no flags Details
Patch (16.26 KB, patch)
2019-03-26 16:22 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews101 for mac-highsierra (2.56 MB, application/zip)
2019-03-26 17:09 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews104 for mac-highsierra-wk2 (3.22 MB, application/zip)
2019-03-26 17:45 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews113 for mac-highsierra (2.24 MB, application/zip)
2019-03-26 18:11 PDT, Build Bot
no flags Details
Patch (17.64 KB, patch)
2019-03-27 09:22 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff
Patch (17.09 KB, patch)
2019-04-02 15:37 PDT, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Anne van Kesteren 2019-03-23 02:02:10 PDT
Per (updated) test in https://github.com/web-platform-tests/wpt/pull/13365 the size isn't known.
Comment 1 Radar WebKit Bug Importer 2019-03-23 18:04:53 PDT
<rdar://problem/49191412>
Comment 2 Chris Dumez 2019-03-26 15:13:40 PDT
Created attachment 366013 [details]
Patch
Comment 3 Build Bot 2019-03-26 16:17:13 PDT
Comment on attachment 366013 [details]
Patch

Attachment 366013 [details] did not pass mac-ews (mac):
Output: https://webkit-queues.webkit.org/results/11676610

New failing tests:
imported/w3c/web-platform-tests/xhr/event-error-order.sub.html
Comment 4 Build Bot 2019-03-26 16:17:15 PDT
Created attachment 366018 [details]
Archive of layout-test-results from ews103 for mac-highsierra

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews103  Port: mac-highsierra  Platform: Mac OS X 10.13.6
Comment 5 Chris Dumez 2019-03-26 16:20:32 PDT
--- /Volumes/Data/EWS/WebKit/WebKitBuild/Release/layout-test-results/imported/w3c/web-platform-tests/xhr/event-error-order.sub-expected.txt
+++ /Volumes/Data/EWS/WebKit/WebKitBuild/Release/layout-test-results/imported/w3c/web-platform-tests/xhr/event-error-order.sub-actual.txt
@@ -1,3 +1,3 @@
 
-FAIL XMLHttpRequest: event - error (order of events) assert_equals: expected "upload.loadstart(0,12,true)" but got "upload.loadstart(0,0,false)"
+PASS XMLHttpRequest: event - error (order of events) 

I guess Mac-wk1 has a platform-specific expectation file.
Comment 6 Chris Dumez 2019-03-26 16:22:50 PDT
Created attachment 366021 [details]
Patch
Comment 7 Build Bot 2019-03-26 17:09:34 PDT
Comment on attachment 366021 [details]
Patch

Attachment 366021 [details] did not pass mac-ews (mac):
Output: https://webkit-queues.webkit.org/results/11677153

New failing tests:
imported/w3c/web-platform-tests/xhr/event-timeout-order.htm
Comment 8 Build Bot 2019-03-26 17:09:36 PDT
Created attachment 366026 [details]
Archive of layout-test-results from ews101 for mac-highsierra

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews101  Port: mac-highsierra  Platform: Mac OS X 10.13.6
Comment 9 Build Bot 2019-03-26 17:45:38 PDT
Comment on attachment 366021 [details]
Patch

Attachment 366021 [details] did not pass mac-wk2-ews (mac-wk2):
Output: https://webkit-queues.webkit.org/results/11677513

New failing tests:
imported/w3c/web-platform-tests/xhr/event-timeout-order.htm
Comment 10 Build Bot 2019-03-26 17:45:40 PDT
Created attachment 366028 [details]
Archive of layout-test-results from ews104 for mac-highsierra-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews104  Port: mac-highsierra-wk2  Platform: Mac OS X 10.13.6
Comment 11 Build Bot 2019-03-26 18:11:19 PDT
Comment on attachment 366021 [details]
Patch

Attachment 366021 [details] did not pass mac-debug-ews (mac):
Output: https://webkit-queues.webkit.org/results/11677539

New failing tests:
imported/w3c/web-platform-tests/xhr/event-timeout-order.htm
Comment 12 Build Bot 2019-03-26 18:11:21 PDT
Created attachment 366031 [details]
Archive of layout-test-results from ews113 for mac-highsierra

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews113  Port: mac-highsierra  Platform: Mac OS X 10.13.6
Comment 13 Chris Dumez 2019-03-27 09:22:19 PDT
Created attachment 366075 [details]
Patch
Comment 14 WebKit Commit Bot 2019-03-27 11:10:57 PDT
Comment on attachment 366075 [details]
Patch

Clearing flags on attachment: 366075

Committed r243551: <https://trac.webkit.org/changeset/243551>
Comment 15 WebKit Commit Bot 2019-03-27 11:10:59 PDT
All reviewed patches have been landed.  Closing bug.
Comment 16 Chris Dumez 2019-04-02 13:30:17 PDT
Reverted r243551 for reason:

Seems to have broken file uploads to SoundCloud

Committed r243756: <https://trac.webkit.org/changeset/243756>
Comment 17 Brady Eidson 2019-04-02 13:37:32 PDT
(In reply to Chris Dumez from comment #16)
> Reverted r243551 for reason:
> 
> Seems to have broken file uploads to SoundCloud
> 
> Committed r243756: <https://trac.webkit.org/changeset/243756>

Steps to reproduce:
1 - Login to soundcloud
2 - "Upload"
3 - Pick an audio file and upload it

Results:
The progress bar for the upload never shows any progress (Hadn't gotten around to checking the JS console, probably should have)

Expected:
The process bar shows progress right away.

Notes: I found this and explored on device. Unclear if it affects desktop/sim the same
Comment 18 Chris Dumez 2019-04-02 15:36:18 PDT
Comment on attachment 366075 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=366075&action=review

> Source/WebCore/xml/XMLHttpRequest.cpp:949
> +    if (m_response.isNull()) {

This is the part that broke SoundCloud. SoundCloud does not seem to send us a response and get expects progress events, we therefore cannot delay sending the progress events until we have a response.
Comment 19 Chris Dumez 2019-04-02 15:37:28 PDT
Created attachment 366544 [details]
Patch
Comment 20 Chris Dumez 2019-04-02 16:00:52 PDT
Comment on attachment 366544 [details]
Patch

Clearing flags on attachment: 366544

Committed r243765: <https://trac.webkit.org/changeset/243765>
Comment 21 Chris Dumez 2019-04-02 16:00:54 PDT
All reviewed patches have been landed.  Closing bug.