avoid Promise contructor anti-pattern in wpt event RTCPeerConnection-helper.js to surface errors.
Categories
(Core :: WebRTC, defect, P2)
Tracking
()
People
(Reporter: jib, Assigned: jib)
References
Details
Attachments
(1 file)
We're seeing some TIMEOUTs in RTCRtpReceiver-getSynchronizationSources.https.html in windows 7 debug builds.
It looks something may be failing in our implementation, but the failure may be covered up as a timeout in the listenForSSRCs helper:
function listenForSSRCs(t, receiver) {
return new Promise((resolve) => {
function listen() {
=> const ssrcs = receiver.getSynchronizationSources(); // throws?
=> assert_true(ssrcs != undefined); // throws?
if (ssrcs.length > 0) {
resolve(ssrcs);
return;
}
t.step_timeout(listen, 0);
};
listen();
});
}
setTimeout
has terrible error-handling characteristics, so these should be rewritten to avoid the Promise constructor anti-pattern to better surface errors in the test harness.
Assignee | ||
Comment 1•4 years ago
|
||
Assignee | ||
Comment 2•4 years ago
|
||
(In reply to Jan-Ivar Bruaroey [:jib] (needinfo? me) from comment #0)
We're seeing some TIMEOUTs in RTCRtpReceiver-getSynchronizationSources.https.html in windows 7 debug builds.
Or rather we were seeing timeouts before the main thread rescheduling, which is what the above link is, i.e. unexpected PASS:
The [task 2020-06-10T11:31:54.373Z] 11:31:54 INFO - TEST-UNEXPECTED-PASS | /webrtc/RTCRtpReceiver-getSynchronizationSources.https.html | [audio] getSynchronizationSources() eventually returns a non-empty list - expected TIMEOUT
Assignee | ||
Comment 3•4 years ago
|
||
Assignee | ||
Comment 4•4 years ago
|
||
Pushed by jbruaroey@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/ab4006856bdc avoid Promise contructor anti-pattern in event RTCPeerConnection-helper.js to surface errors to harness. r=ng,bwc
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/24138 for changes under testing/web-platform/tests
Can't merge web-platform-tests PR due to failing upstream checks: Github PR https://github.com/web-platform-tests/wpt/pull/24138 * Community-TC (pull_request) (https://community-tc.services.mozilla.com/tasks/groups/YY42N_lpTnmwsdkQmsT3yA)
Comment 8•4 years ago
|
||
bugherder |
Upstream PR merged by jgraham
Assignee | ||
Updated•4 years ago
|
Comment 10•4 years ago
|
||
bugherder uplift |
Description
•