tobie / specref

An open-source, community-maintained database of Web standards & related references.
http://www.specref.org/
Apache License 2.0
165 stars 141 forks source link

Account for WebIDL moving to WHATWG #686

Closed tobie closed 3 years ago

tobie commented 3 years ago

/cc @annevk

tobie commented 3 years ago

Ugh. There's more stuff to cleanup in w3c.json.

tobie commented 3 years ago

See also the conversation at: https://github.com/tobie/specref/issues/677

/cc @marcoscaceres

annevk commented 3 years ago

What would the best course of action be here, also delete the -1 and -2 aliases? Does that need a policy discussion/decision now the document has moved? And if yes, is that documented somewhere since I'm not sure what it entails?

tobie commented 3 years ago

@annevk: I'm going to confess having very little time to focus on this atm and don't want to be blocking y'all from moving forward with this. I'm happy with whatever you, @tabatkins, and @marcoscaceres agree to.

annevk commented 3 years ago

Thanks and understood; I hope @marcoscaceres can chime in tomorrow with the best course of action here.

marcoscaceres commented 3 years ago

I think we should do what @tabatkins suggested:

I recommend that WebIDL-1 be changed to an alias of WebIDL

And same with WebIDL-2.

Let me see what's left over in w3c.json...

marcoscaceres commented 3 years ago

Updating this PR locally... will send something up soon.

marcoscaceres commented 3 years ago

ok, did the re-alias so no references are lost.

Now all point to the right place ("WEBIDL").

@tobie, can you give it a once over to make sure it looks right?

annevk commented 3 years ago

I'm afraid this won't work. Both w3c.json (as I understand it) and whatwg.json would be overridden with the next update. whatwg.json is essentially https://resources.whatwg.org/biblio.json.

Instead this information needs to be patched in through overrides.

marcoscaceres commented 3 years ago

Oh yeah, of course... sorry, it's been a while since I hacked on this... if I transfer those aliases to biblio.js, then that's gonna help.... then we need to add the version somehow to "WEBIDL" in whatwg.json

marcoscaceres commented 3 years ago

@annevk, can we add the version directly to "biblio.json" on the WHATWG side?

annevk commented 3 years ago

On the WHATWG side we generate that file automatically and don't have a good way of adding additional data to it. We could probably put something together, but I'd rather we do it here somehow.

marcoscaceres commented 3 years ago

Ok, I'll investigate.

tobie commented 3 years ago

Have you tried running an update over your code changes? It might well work?

marcoscaceres commented 3 years ago

Have you tried running an update over your code changes? It might well work?

No. Which scripts should I run?

marcoscaceres commented 3 years ago

Ok, this works for me locally (if I manually do what the overrides are doing)... Do I need to commit with overwrites in place?

(also, how do I run the overwrites)?

marcoscaceres commented 3 years ago

I merged in the refs/w3c.json and refs/whatwg.json changes, which would be equivalent to what the overwrite script would do (even if they get blown away on update). Just to show it works.

tobie commented 3 years ago

Not behind my desk atm, sorry for not being super responsive.

You want to just run the following lines: https://github.com/tobie/specref/blob/main/scripts/update-all#L39-L55

marcoscaceres commented 3 years ago

@tobie no problem. I'll finish this off tomorrow or later today... quick questions: what do I set the GITHUB_REPO env var to?

tobie commented 3 years ago

Don’t run the whole script. Just copy/paste these lines.

marcoscaceres commented 3 years ago

Argh... not quite right yet. Getting there tho.

marcoscaceres commented 3 years ago

Ok, I think I got it... 😅

marcoscaceres commented 3 years ago

Fun thing: CSS now tries to add the old WebIDL reference back in.

tobie commented 3 years ago

This LGTM. Let's deploy and see what happens.

annevk commented 3 years ago

Thanks @marcoscaceres and @tobie! I hope this works.

tobie commented 3 years ago

Continuing the thread in #677 as notifications on merged pull requests are uncharted territory to me.