-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make encrypted-media an alias of encrypted-media-2 #810
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can't you also fix this one in the file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apparently, I can't... If I update
w3c.json
directly, theencrypted-media
entry gets back to being an alias ofencrypted-media-1
next time thew3c.js
script is run.Looking into it, I suspect that's due to
tr.rdf
, which contains:I suppose the intrepretation is that since
encrypted-media-1
used to be known asencrypted-media
, thenencrypted-media
should be an alias ofencrypted-media-1
. That interpretation is sound in the absence of better info. Unfortunatelytr.rdf
does not know much about specification series either...There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't want to block you on this, but can't you fix this upstream?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Upstream in
tr.rdf
? As far as I know, the file is maintained as is because several projects (including Specref) need it, but without any attempt to add new features at this point. I don't know where the code that producestr.rdf
file lies in practice. It may not be public. @deniak would know!Now, there is nothing to fix per se in
tr.rdf
. The file just does not know thatencrypted-media-1
andencrypted-media-2
are part of the same series of specs whose shortname isencrypted-media
, and that the second level is the current one. It just knows that theencrypted-media-1
spec used to be known asencrypted-media
, which is indeed correct. The W3C API would be a better source for Specref down the road, and would allow to add proper support for specification series. Same thing, that's not really a fix though, more a whole new feature ;)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
iirc, fixing those somewhere was possible (as it also maps what happens to redirects, e.g. https://www.w3.org/TR/encrypted-media/ -> https://www.w3.org/TR/encrypted-media-2/), but no problem if that's an issue for you to fix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it? Looking at the
w3c.js
script in Specref, the only way to end up with an alias seems to be with thisformerShortname
mechanism. Thetr.rdf
file has a notion of superseding that gets used in Specref to flag entries as obsoleted by another entry, but that's not what I'd like here: I'd like people to be able to continue referencing the latest version of the spec withencrypted-media
. Also, ReSpec at least does not seem to warn authors when an obsoleted spec gets referenced.Specref has a notion of levels - code is in
leveled.js
- but that's a hardcoded list (with only WebIDL so far), and it seems to be more about merging entries.What makes this case a pain is that
encrypted-media
used to be the shortname of the spec that is nowencrypted-media-1
. It now is the series shortname of a family of specs whose current level isencrypted-media-2
. Things would have been easier ifencrypted-media-1
had existed from day 1: there would have been noencrypted-media
entry (similar to the way there is nocss-fonts
entry but onlycss-fonts-3
,css-fonts-4
,css-fonts-5
), which would have avoided any confusion. The starting point for this PR is that authors of specs referencingencrypted-media
now get confused because the reference still goes to level 1.Instead of trying to make things somewhat work in Specref, perhaps we should not do anything and rather ask people to use
encrypted-media-2
, at least until we figure out a way to support series shortnames in Specref?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just for the record,
tr.rdf
is generated from data we have in the database. Now, as @tidoust mentioned, it lacks some features such as the series, which creates some problems like the one you are discussing. The goal is to discontinue it in favor of the API but iftr.rdf
generates some infinite loop because of these former shortnames, I can try to untangle the data.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, there's a bunch of elements in
tr.rdf
doing things like:That's what I had in mind. But don't feel like this is what you have to do at all. I'm totally fine merging this as is.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, I recorded the possibility to support specification series in #811. Will merge as is :)