Closed
Bug 1155923
Opened 10 years ago
Closed 9 years ago
Unprefix WebRTC
Categories
(Core :: WebRTC, defect, P3)
Core
WebRTC
Tracking
()
RESOLVED
FIXED
mozilla44
backlog | webrtc/webaudio+ |
People
(Reporter: mt, Assigned: mt)
References
(Blocks 3 open bugs)
Details
(Keywords: dev-doc-needed, site-compat, Whiteboard: [spec compliance])
Attachments
(4 files)
This API isn't going to change in a way that will break compatibility. Besides, we shouldn't have done this in the first place.
Identified:
mozRTCPeerConnection
mozRTCSessionDescription
mozRTCIceCandidate
HTMLMediaElement.mozSrcObject
For the conservative, we can add aliases for a couple of releases.
Comment 1•10 years ago
|
||
mozGetUserMedia
Assignee | ||
Comment 2•10 years ago
|
||
(In reply to Randell Jesup [:jesup] from comment #1)
> mozGetUserMedia
I considered it, but mediaDevices.getUserMedia isn't prefixed. We can kill mozGetUserMedia when we remove the other prefixes (or maybe sooner).
Updated•10 years ago
|
Assignee | ||
Comment 3•9 years ago
|
||
Bug 1155923 - Removing moz prefix from RTC interfaces, r?jesup,smaug
Attachment #8651281 -
Flags: review?(rjesup)
Attachment #8651281 -
Flags: review?(bugs)
Assignee | ||
Comment 4•9 years ago
|
||
Bug 1155923 - Temporarily restoring moz-prefixed interface, r?jesup,smaug
Attachment #8651282 -
Flags: review?(rjesup)
Attachment #8651282 -
Flags: review?(bugs)
Assignee | ||
Comment 5•9 years ago
|
||
It has become abundantly clear - even from just looking at this within the tree - that outright removing these interfaces will cause a huge number of problems. For starters, all the adapter code that exists is in one of the following forms:
tmp = webkitRTCPeerConnection || mozRTCPeerConnection; x = new tmp(); // Tokbox does this
if (navigator.mozUserMedia) x = new mozRTCPeerConnection();
Few use the arguably correct form:
RTCPeerConnection = RTCPeerConnection || webkitRTCPeerConnection || mozRTCPeerConnection;
So, my plan is to have two patches:
1. remove the prefix
2. create prefixed aliases for the interfaces, each with a deprecation warning that goes to the console
The second part is a little ugly, but I will provide a pointer to this bug in the code. Hopefully we can back out the second patch when we are ready to remove the prefix properly.
Assignee | ||
Updated•9 years ago
|
Keywords: leave-open
Comment 6•9 years ago
|
||
(In reply to Martin Thomson [:mt:] from comment #5)
> So, my plan is to have two patches:
>
> 1. remove the prefix
> 2. create prefixed aliases for the interfaces, each with a deprecation
> warning that goes to the console
>
> The second part is a little ugly, but I will provide a pointer to this bug
> in the code. Hopefully we can back out the second patch when we are ready
> to remove the prefix properly.
+1. I was about to ask about this very thing, as no overlap would cause considerable problems (as you note).
Comment 7•9 years ago
|
||
>+++ b/dom/webidl/WebrtcDeprecated.webidl
>...
>+ * This file includes all the deprecated mozRTC prefixed interfaces.
>+ *
I don't see the file containing any deprecated interfaces, only deprecated properties. So, fix the comment.
Updated•9 years ago
|
Attachment #8651281 -
Flags: review?(bugs) → review+
Comment 8•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
I don't see how this approach could work, or at least the asserts might fire if the page overrides mozFoo properties in the global object.
The property might not be object anymore or so.
Couldn't we just have something like
[Same-stuff-here-as-for-SomeInterface]
interface moz<SomeInterface> : SomeInterface
{
}
Attachment #8651282 -
Flags: review?(bugs) → review-
Assignee | ||
Comment 9•9 years ago
|
||
Good catch on the page overrides, I was working on the (bad) assumption that WebIDL interfaces weren't writeable.
I tried the inheritance thing, and getting the [Deprecated] stuff working was tricky. [Deprecated] only works on attributes and functions. I'll try again.
Assignee | ||
Updated•9 years ago
|
Attachment #8651281 -
Attachment description: MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r?jesup,smaug → MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r?jesup=smaug
Attachment #8651281 -
Flags: review+
Assignee | ||
Comment 10•9 years ago
|
||
Comment on attachment 8651281 [details]
MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Bug 1155923 - Removing moz prefix from RTC interfaces, r?jesup=smaug
Assignee | ||
Comment 11•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Bug 1155923 - Add Deprecated attribute to interfaces, r?peterv
Attachment #8651282 -
Attachment description: MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r?jesup,smaug → MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r?peterv
Attachment #8651282 -
Flags: review?(rjesup)
Attachment #8651282 -
Flags: review?(peterv)
Attachment #8651282 -
Flags: review-
Assignee | ||
Comment 12•9 years ago
|
||
Bug 1155923 - Temporarily restoring moz-prefixed interface, r?jesup,smaug
Attachment #8651937 -
Flags: review?(rjesup)
Attachment #8651937 -
Flags: review?(bugs)
Assignee | ||
Comment 13•9 years ago
|
||
OK, the final form of this required a little modification of the WebIDL bindings to support [Deprecated] attributes on interfaces. But it works (my earlier attempt ran afoul of some strangeness in the codegen because I was using A implements B, which causes the codegen to #include "nsIB.h" and explode since B is JS-implemented).
The only catch that I found here is that the deprecated warning doesn't trigger for static methods. RTCPeerConnection.generateCertificate is accessible as mozRTCPeerConnection.generateCertificate, but it doesn't trigger a deprecation warning. I think that we can live with that.
Assignee: nobody → martin.thomson
Updated•9 years ago
|
Attachment #8651281 -
Flags: review?(rjesup) → review+
Comment 14•9 years ago
|
||
Comment on attachment 8651281 [details]
MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
https://reviewboard.mozilla.org/r/16885/#review15021
::: browser/components/loop/test/shared/validate_test.js:21
(Diff revision 1)
> - var mozRTC;
> + var rtcsd;
Not loving the var name, but didn't love the one before either. No big deal.
::: dom/webidl/WebrtcDeprecated.webidl:13
(Diff revision 2)
> +interface WebrtcDeprecated
webidl - needs DOM peer
Comment 15•9 years ago
|
||
Comment on attachment 8651937 [details]
MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
https://reviewboard.mozilla.org/r/17033/#review15171
Ship It!
Attachment #8651937 -
Flags: review?(rjesup) → review+
Comment 16•9 years ago
|
||
- "RTCIceCandidate",
-// IMPORTANT: Do not change this list without review from a DOM peer!
- "RTCPeerConnection",
-// IMPORTANT: Do not change this list without review from a DOM peer!
- "RTCSessionDescription",
+ "mozRTCIceCandidate",
+// IMPORTANT: Do not change this list without review from a DOM peer!
+ "mozRTCPeerConnection",
+// IMPORTANT: Do not change this list without review from a DOM peer!
+ "mozRTCSessionDescription",
I don't understand this change. How can you remove support for non-prefixed interfaces?
Don't you just want to add those moz-prefixed ones?
Updated•9 years ago
|
Attachment #8651937 -
Flags: review?(bugs) → review+
Comment 17•9 years ago
|
||
Do we need to post an "Intent to implement RTCPeerConnection partially" on dev.platform? That's what we did for srcObject, which was arguably a smaller change than this.
There are still implementation pieces missing and API changes happening in RTCPeerConnection, like the switch from streams to tracks.
Assignee | ||
Comment 18•9 years ago
|
||
Sounds like it couldn't hurt.
Assignee | ||
Comment 19•9 years ago
|
||
(In reply to Olli Pettay [:smaug] (high review load) from comment #16)
> - "RTCIceCandidate",
> -// IMPORTANT: Do not change this list without review from a DOM peer!
> - "RTCPeerConnection",
> -// IMPORTANT: Do not change this list without review from a DOM peer!
> - "RTCSessionDescription",
> + "mozRTCIceCandidate",
> +// IMPORTANT: Do not change this list without review from a DOM peer!
> + "mozRTCPeerConnection",
> +// IMPORTANT: Do not change this list without review from a DOM peer!
> + "mozRTCSessionDescription",
> I don't understand this change. How can you remove support for non-prefixed
> interfaces?
>
> Don't you just want to add those moz-prefixed ones?
That's a rebase error. I'll fix it. The intent is to have patch 1 remove mozRTC* and add RTC*. Patch 2 should only restore mozRTC*, leaving RTC* in place.
Assignee | ||
Comment 20•9 years ago
|
||
Comment on attachment 8651281 [details]
MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Attachment #8651281 -
Attachment description: MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r?jesup=smaug → MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Assignee | ||
Comment 21•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Bug 1155923 - Add Deprecated attribute to interfaces, r?peterv
Assignee | ||
Comment 22•9 years ago
|
||
Comment on attachment 8651937 [details]
MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Attachment #8651937 -
Attachment description: MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r?jesup,smaug → MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Attachment #8651937 -
Flags: review+
Comment 23•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
https://reviewboard.mozilla.org/r/16887/#review16341
Please add some tests to the .webidl files in dom/bindings/test (similar to the existing tests for Desprecated on attributes and methods).
::: dom/bindings/Codegen.py:1688
(Diff revision 3)
> + """ % self.descriptor.interface.getExtendedAttribute("Deprecated")[0])
Please add a helper for this in BindingUtils.cpp that you can call from here and from the code that you copied this from.
::: dom/bindings/Codegen.py:12822
(Diff revision 3)
> + any(m.getExtendedAttribute("Deprecated") for m in iface.members + [iface]))
Why is the change needed? Doesn't the existing " + [iface]" cover this already?
Attachment #8651282 -
Flags: review?(peterv)
Updated•9 years ago
|
Keywords: dev-doc-needed
Updated•9 years ago
|
Keywords: site-compat
Assignee | ||
Comment 25•9 years ago
|
||
https://reviewboard.mozilla.org/r/16887/#review16341
> Please add a helper for this in BindingUtils.cpp that you can call from here and from the code that you copied this from.
I did that, then discovered that I the second check was unnecessary - the new check was sufficient to cover all the cases. Still, I think that it's cleaner to have the code in BindingUtils.
Assignee | ||
Comment 26•9 years ago
|
||
Comment on attachment 8651281 [details]
MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Assignee | ||
Comment 27•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Bug 1155923 - Add Deprecated attribute to interfaces, r?peterv
Attachment #8651282 -
Flags: review?(peterv)
Assignee | ||
Comment 28•9 years ago
|
||
Comment on attachment 8651937 [details]
MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Comment 29•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
https://reviewboard.mozilla.org/r/16887/#review17695
Nice!
Attachment #8651282 -
Flags: review?(peterv) → review+
Assignee | ||
Comment 30•9 years ago
|
||
Comment on attachment 8651281 [details]
MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Attachment #8651281 -
Flags: review?(bugs)
Assignee | ||
Comment 31•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Attachment #8651282 -
Attachment description: MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r?peterv → MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Assignee | ||
Updated•9 years ago
|
Attachment #8651937 -
Flags: review?(bugs)
Assignee | ||
Comment 32•9 years ago
|
||
Comment on attachment 8651937 [details]
MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Assignee | ||
Comment 33•9 years ago
|
||
Comment on attachment 8651281 [details]
MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Carrying r+, damned reviewboard
Attachment #8651281 -
Flags: review?(bugs) → review+
Assignee | ||
Comment 34•9 years ago
|
||
Comment on attachment 8651937 [details]
MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Carrying r=smaug, sorry about that, I blame RB.
Attachment #8651937 -
Flags: review?(bugs) → review+
Comment 35•9 years ago
|
||
Added the site compatibility doc: https://www.fxsitecompat.com/en-US/docs/2015/webrtc-interfaces-have-been-unprefixed/
Assignee | ||
Updated•9 years ago
|
Keywords: checkin-needed
Comment 36•9 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/2981db92416a
https://hg.mozilla.org/integration/mozilla-inbound/rev/6ac38acd6ab2
https://hg.mozilla.org/integration/mozilla-inbound/rev/321a932e01a7
Keywords: checkin-needed
Comment 37•9 years ago
|
||
sorry backed out for test failures like https://treeherder.mozilla.org/logviewer.html#?job_id=14797696&repo=mozilla-inbound
Flags: needinfo?(martin.thomson)
Comment 38•9 years ago
|
||
Assignee | ||
Comment 39•9 years ago
|
||
Comment on attachment 8651281 [details]
MozReview Request: Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Bug 1155923 - Removing moz prefix from RTC interfaces, r=jesup,smaug
Attachment #8651281 -
Flags: review+
Assignee | ||
Comment 40•9 years ago
|
||
Comment on attachment 8651282 [details]
MozReview Request: Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Bug 1155923 - Add Deprecated attribute to interfaces, r=peterv
Assignee | ||
Comment 41•9 years ago
|
||
Comment on attachment 8651937 [details]
MozReview Request: Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Bug 1155923 - Temporarily restoring moz-prefixed interface, r=jesup,smaug
Attachment #8651937 -
Flags: review+
Assignee | ||
Comment 42•9 years ago
|
||
Bug 1155923 - Updating webplatform-tests, r?jib
Attachment #8666864 -
Flags: review?(jib)
Comment 43•9 years ago
|
||
Comment on attachment 8666864 [details]
MozReview Request: Bug 1155923 - Updating webplatform-tests, r?jib
https://reviewboard.mozilla.org/r/20609/#review18489
lgtm.
Attachment #8666864 -
Flags: review?(jib) → review+
Assignee | ||
Updated•9 years ago
|
Keywords: leave-open → checkin-needed
Comment 45•9 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/42657128cf56
https://hg.mozilla.org/integration/mozilla-inbound/rev/f8f71e377d67
https://hg.mozilla.org/integration/mozilla-inbound/rev/de9abaf6b170
https://hg.mozilla.org/integration/mozilla-inbound/rev/6d20341337cc
Keywords: checkin-needed
Comment 46•9 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/42657128cf56
https://hg.mozilla.org/mozilla-central/rev/f8f71e377d67
https://hg.mozilla.org/mozilla-central/rev/de9abaf6b170
https://hg.mozilla.org/mozilla-central/rev/6d20341337cc
https://hg.mozilla.org/mozilla-central/rev/143a6814b1d5
Status: NEW → RESOLVED
Closed: 9 years ago
status-firefox44:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla44
Comment 48•9 years ago
|
||
(In reply to Martin Thomson [:mt:] from comment #2)
> (In reply to Randell Jesup [:jesup] from comment #1)
> > mozGetUserMedia
>
> I considered it, but mediaDevices.getUserMedia isn't prefixed. We can kill
> mozGetUserMedia when we remove the other prefixes (or maybe sooner).
mozGetUserMedia is keeping a lot of web-platform tests from passing (like all of mediacapture) so we should push for updating them upstream then. Does this sound like something you want to do Martin? :-)
Flags: needinfo?(martin.thomson)
Comment 49•9 years ago
|
||
(In reply to Andreas Pehrson [:pehrsons] (Telenor) from comment #48)
> mozGetUserMedia is keeping a lot of web-platform tests from passing (like
> all of mediacapture) so we should push for updating them upstream then. Does
> this sound like something you want to do Martin? :-)
Is this on treeherder or locally on your system? Last time I checked, quite some time ago, we were passing most of them if the tests got started with the option to use the prefixes.
Comment 50•9 years ago
|
||
(In reply to Nils Ohlmeier [:drno] from comment #49)
> (In reply to Andreas Pehrson [:pehrsons] (Telenor) from comment #48)
> Is this on treeherder or locally on your system?
Both.
I didn't try with prefixes, nor do I know how to :-)
Assignee | ||
Comment 51•9 years ago
|
||
I'd rather change the web-platform tests to point to navigator.mediaDevices.getUserMedia. Fixing navigator.mozGetUserMedia isn't that much fun.
Flags: needinfo?(martin.thomson)
Assignee | ||
Comment 52•9 years ago
|
||
Oh, we could add [Deprecated] on navigator.mozGetUserMedia if that would make you happy. That's a trivial change; the only problem being that it would require DOM peer review.
Comment 53•9 years ago
|
||
(In reply to Martin Thomson [:mt:] from comment #51)
> I'd rather change the web-platform tests to point to
> navigator.mediaDevices.getUserMedia.
Yeah, this is exactly what I am trying to push for.
You need to log in
before you can comment on or make changes to this bug.
Description
•