Skip to content
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

Wrong ordering of stylesheets: W3C TR style sheet must be last #2242

Closed
tidoust opened this issue Mar 8, 2022 · 5 comments
Closed

Wrong ordering of stylesheets: W3C TR style sheet must be last #2242

tidoust opened this issue Mar 8, 2022 · 5 comments

Comments

@tidoust
Copy link
Contributor

tidoust commented Mar 8, 2022

The latest version of the Pubrules checker (v6.1.4), released last week, seems to check the W3C TR style sheet must be last rule more thoroughly, and now chokes on <style> tags that Bikeshed puts after the link to the W3C TR style sheet (both those added by default and custom styles that authors may choose to add).

One example that passed PubRules last week but no longer does is https://www.w3.org/pubrules/?url=https://www.w3.org/TR/2022/WD-webgpu-20220303/&profile=auto

@jennyliang220
Copy link

The rule existed in Pubrules for a long time, but the check was loose before. It's fixed now and would report an error to documents with custom styles.

To fix this issue, please insert the custom style before the W3C stylesheet, so that the W3C stylesheet doesn't get overlayed. @tabatkins

https://github.com/tabatkins/bikeshed/blob/bda455a127686b75ef54c203463b06a201c7edc4/bikeshed/Spec.py#L287-L289

Good:

<style> #id {custom: styles; } </style>
<link rel="stylesheet" href="https://www.w3.org/StyleSheets/TR/2021/W3C-NOTE">

@tidoust
Copy link
Contributor Author

tidoust commented Mar 9, 2022

@jennyliang220, the code you quoted runs if Prepare for TR is set. Could it be that Echidna no longer sets that flag for some reason? (or never set it but that went unnoticed?) If I add "Prepare for TR: yes" to the metadata locally, that seems to fix the issue in particular. I don't think that we should require all spec authors to add that directive themselves.

That said, having the same ordering of stylesheets in Editor's Drafts and in TR documents could be a good thing to have, as this may create hard to spot cascading implications (an editor who defines custom styles in an ED would expect these styles to run equally well in the TR version).

@tidoust
Copy link
Contributor Author

tidoust commented Mar 9, 2022

Looking at it again, Echidna is not where the problem lies. It's rather the spec-prod action that should set the setting (similar to the way the bikeshed echidna command sets it).

I created an issue against spec-prod (see w3c/spec-prod#128) and am closing this issue as Bikeshed works as intended.

@tidoust tidoust closed this as completed Mar 9, 2022
@tabatkins
Copy link
Collaborator

tabatkins commented Mar 9, 2022

Yes, echidna should Prepare for TR, as that's what triggers the W3C stylesheets to move to the end of the head.

That said, I was also promised that changes to PubRules like this would be announced ahead of time so that sudden "nobody can publish with Bikeshed" issues like this wouldn't happen again, after the Process 2021 debacle. @plehegar ?

@svgeesus
Copy link
Contributor

svgeesus commented Mar 9, 2022

I was also promised that changes to PubRules like this would be announced ahead of time

Yes. It is becoming an increasing problem that a spec which was published a year ago, a month ago, a week ago will now no longer publish because un-discussed and un-announced changes to pubrules are only discovered by the editors or staff contacts when a publication fails.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants