-
Notifications
You must be signed in to change notification settings - Fork 163
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
Proposed solution to make grammar changes less disruptive #477
Comments
FWIW, if parsing fails, I just place the IDL back into the
I've be supportive of this, but maybe with a shorter cycle (3 months max). Editors don't usually take action until things actually break - and I've seen technical debt accumulate to breaking point (e.g., the Web Audio spec). Breaking things lights (controlled) fires, and we are pretty good at putting them out. |
I don't think this is a good idea. We need to be able to evolve Web IDL without the burden of old syntax, and we need to be able to push the ecosystem forward as fast as we did with serializers. If some specs are having trouble, then I think this should be solved at a tooling level, not a spec level. E.g. a deprecated features mode could be added to the tools, or we could make it easier to build specs using last-known-good revisions of tools instead of always-master. |
I agree. Just need to keep communicating breaking changes upstream by filing bugs on the various tools (as has been done quite effectively lately, so huge thanks to everyone doing that! ❤️).
Agree. We can definitely work on supporting a compat mode on the webidl2.js side. |
I think what would help is not landing the IDL PR until the necessary downstream bugs are filed. |
A part of the solution could be web-platform-tests/wpt#7784, which should mean that web-platform-tests IDL is very rarely out of sync with the spec. So, the process for replacing some bit of syntax would be:
Not exactly streamlined, but more fun that updating IDL in wpt manually as I was doing this time. |
@annevk wrote:
Unless they're acted on immediately, this won't prevent either a period where the spec is updated and the tools aren't or the risk of important merge conflicts if we wait until the tools are updated to merge the spec. No? |
We could additionally wait for at least one such tool to also have a PR (preferably the Bikeshed dependency). If we additionally fix web-platform-tests I think we'd be mostly covered. It'll take a little longer, but should be smoother. And the specification PR will get the benefits of multiple reviews. |
I like the idea of having a deprecation period. It's not reasonable to expect all spec authors to be experts in the latest changes in specification infrastructure; that will be a burden on them, and in mitigating the burden, there will just be more conservatism in changes to WebIDL. Especially if we make drastic changes, such as the ones I'm suggesting in #485 , we may want a long period, such as two years, for all the specs and tools to update, together with releasing tooling to translate from one version to another (not sure if this already exists). |
We have no translation tooling available. That would probably be good, even if we manage to batch all changes we want to make. |
Translation tooling should be relatively easy to build on top of Bikeshed and ReSpec's parser, or as a standalone tool to use in post processing. |
Perhaps we can consider this more-or-less solved thanks to @saschanaz's @autokagami + filing various bugs against implementations? We've used that tactic a few times now with relatively little fallout (though it's still somewhat intensive of course). |
Goal
Allow faster and easier changes to the grammar while being less disruptive to specs and tools relying on WebIDL.
Issue
Grammar changes are particularly problematic as removed syntax causes parsers to fail. This has the following consequence:
Working around those issues creates yet another level of problems:
Proposed solution
Don't remove grammar right away. Instead, mark grammar as deprecated for a given period of time (6 months?). Have all the tools (parsers, idlharness, ReSpec, Bikeshed) implement the same version of the grammar (with the same deprecation warnings) and sync dropping off support.
Add information in the spec as to when and what tools may/should emit as warning for deprecated syntax.
Immediate targets
serializer
has been mostly fixed, so it's probably not worth adding it back to the spec and marking it as deprecated (also because it seems like a lot of work). @gsnedders, @foolip: can you confirm?implements
is a great candidate, however.Would love to hear @plinss's, @marcoscaceres's, @tabatkins's, @bzbarsky's, @annevk's and @domenic's thoughts on the topic.
The text was updated successfully, but these errors were encountered: