This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
The DOM spec defines what the description are for each exception name: http://www.w3.org/TR/dom/#error-names But the EME spec is also specifying optional messages/descriptions for exception names that are defined in the main DOM spec linked above: https://dvcs.w3.org/hg/html-media/raw-file/default/encrypted-media/encrypted-media.html#exceptions As far as we can tell there's no wiggle room in the DOM spec to allow the exception messages to vary. So either we should add new exceptions for EME with the desired codes, or we should drop the new messages.
In particular, .message is up to the UA and is expected to be localized and such. You cannot state what the content should be as a requirement.
I believe the summary should be changed to "Do not specify messages for exceptions." Chris, do you agree? The most important action is to remove the "and that has the message" text from the algorithms. Is there any value documenting how the exceptions are used in the table? The Possible Messages column could be changed to specified causes along with slight changes to the message text. For what it's worth, the table was based modeled after http://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-Exceptions.
(In reply to David Dorwin from comment #2) > I believe the summary should be changed to "Do not specify messages for > exceptions." Chris, do you agree? Yes, I agree. That would be fine. > Is there any value documenting how the exceptions are used in the table? The > Possible Messages column could be changed to specified causes along with > slight changes to the message text. I think changing the table to be a list reasons why the exceptions fire is reasonable. > For what it's worth, the table was based > modeled after http://www.w3.org/TR/WebCryptoAPI/#SubtleCrypto-Exceptions. Then by the same rationale, that table needs to change too. ;)
Filed bug 25912 on crypto.
The table in WebCrypto was in turn inspired by that in IndexedDB: http://www.w3.org/TR/IndexedDB/#exceptions
Indexed DB makes no normative requirements regarding .message (although it is somewhat misleading and the text could be improved).
Implemented in https://dvcs.w3.org/hg/html-media/rev/dfb8b1fdb2ee. I removed the "and that has the message..." text and clarified that the table includes possible causes from the algorithms. For reference, the original messages specified within the algorithms can be seen at https://dvcs.w3.org/hg/html-media/raw-file/ff10d356cc07/encrypted-media/encrypted-media.html.
https://dvcs.w3.org/hg/html-media/rev/4e31f7807448 removes " and that has an appropriate message" from steps that do not specify the exact error name. These were missed in the previous changeset.