-
-
Notifications
You must be signed in to change notification settings - Fork 392
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
PR Preview / respecDocWriter reporting issues. #1345
Comments
Actually, I have regenerated a new PR for the document and https://github.com/w3c/pwpub/blob/c728570d629fa7cc408afa3065930feb7cbf95fd/index.html has the |
Okay, so when following the links manually, on the first navigation, I get a completely blank screen, dumping the content of the DOM tree (copy/paste from the console on Chrome) looks like this: DOM tree dump```html <title>Packaged Web Publications</title> <script src="https://www.w3.org/Tools/respec/respec-w3c-common" class="remove"></script> <script src="common/js/biblio.js" class="remove"></script> <script class="remove"> var respecConfig = { wg: "Publishing Working Group", specStatus: "ED", shortName: "pwpub", edDraftURI: "https://w3c.github.io/pwpub/", editors: [ /* { name: "Dave Cramer", url: 'http://www.hbgusa.com', company: "Hachette Livre", companyURI: "http://www.hbgusa.com"//, w3cid: ? }, */ { name: "Matt Garrish", url: 'http://www.daisy.org', company: "DAISY Consortium", companyURI: "http://www.daisy.org", w3cid: 51655 } ], processVersion: 2017, includePermalinks: true, permalinkEdge: true, permalinkHide: false, diffTool: "http://www.aptest.com/standards/htmldiff/htmldiff.pl", wgURI: "https://www.w3.org/publishing/groups/publ-wg/", wgPublicList: "public-publ-wg", wgPatentURI: "https://www.w3.org/2004/01/pp-impl/100074/status", otherLinks: [ { key: "Repository", data: [{ value: "Github Repository", href: "https://github.com/w3c/pwpub" }] }, { key: "Changes", data: [ // { // value: "Diff to previous version", // href: "diff.html" // }, { value: "Commit history", href: "https://github.com/w3c/pwpub/commits/master" }] } ], localBiblio: biblio }; </script><style id="respec-ui-styles" class="removeOnSave">#respec-ui { position: fixed; display: flex; flex-direction: row-reverse; top: 20px; right: 20px; width: 202px; text-align: right; z-index: 9000; }#respec-pill, .respec-info-button { .respec-info-button:focus, .respec-info-button:hover { #respec-pill:disabled { #respec-pill:disabled, @Keyframes respec-spin { #respec-pill:hover, #respec-menu { #respec-menu li { .respec-save-buttons { .respec-save-button:link { .respec-save-button:link:hover { #respec-ui button:focus, #respec-pill-error { #respec-pill-warning { .respec-warning-list, .respec-warning-list>li, .respec-warning-list>li::before { .respec-warning-list li { .respec-error-list, .respec-error-list li::before { .respec-error-list li { .respec-error-list li>p { #respec-overlay { .respec-modal { @media screen and (min-width: 78em) { .respec-modal h3 { .respec-modal .inside div p { #respec-menu button.respec-option { #respec-menu button.respec-option:hover, .respec-cmd-icon { #respec-ui button.respec-option:last-child { .respec-offending-element { @supports (text-decoration-style: wavy) { .respec-button-copy-paste { p + .respec-button-copy-paste { #specref-ui { #specref-ui header { #specref-ui header h1 { #specref-ui p { #specref-ui p.state { #specref-ui .searchcomponent { } #specref-ui input, #specref-ui label { #specref-ui input[type=search] { #specref-ui button[type=submit]{ #specref-ui button[type=submit]:hover { #specref-ui .result-stats { #specref-ui .specref-results { #specref-ui .specref-results dd + dt { #specref-ui .specref-results a { @media print {
/* Override code highlighter background */ /* --- INLINES --- */ em.rfc2119 { h1 abbr, dfn { a.internalDFN { a.externalDFN { a.bibref { cite .bibref { code { th code { /* --- TOC --- */ .toc a, a .secno, ul.tof, .caption { /* --- TABLE --- */ table.simple { .simple th { .simple th[scope="row"] { .simple td { .simple tr:nth-child(even) { /* --- DL --- */ .section dd > p:first-child { .section dd > p:last-child { .section dd { .section dl.attrs dd, #issue-summary > ul, #issue-summary li, details.respec-tests-details { details.respec-tests-details > * { details.respec-tests-details[open] { details.respec-tests-details[open] > summary { details.respec-tests-details > ul { details.respec-tests-details > li { @media print { This specification defines a packaging format for combining the resources of a Web Publication [[!WPUB]] into a single
Introduction... Terminology
The errors in the console are:
|
(Bringing this to your attention @marcoscaceres, because it seems to break pr-preview for a number of people using ReSpec.) |
@tobie, I think the spec generator might be out of date (I fixed the above bug a few days ago). I'll ask them to update ReSpec. |
@deniak ^^^ actually, given that you are already tagged. Can you make sure the spec generator is using at least 15.7.4? |
@marcoscaceres that's already the case. I updated respec thinking it'll solve the issue after @tobie ping me |
@deniak ok, thanks for confirming. I will yank out the code that causing this problem. It was a hack anyway. |
The problem is still there; I am not sure whether the latest merge was meant to solve the issue. Here is the PR: The file works properly when rawgit is used manually: https://rawgit.com/w3c/wpub/6f47335caf1c02fb97b4be100f2f5fd366bf3c70/index.html But the preview does not appear. (I am just the user, no idea what is happening inside, but @tobie asked me to reopen the issue.) |
This seems to be the same race conditions as before. I can repro the issue on first load, but on the second load, it seems to run normally. |
Thanks, will have another look🕵️ |
I am not sure it is related, but it might. Several of us have experienced a problem on Firefox when displaying, eg, https://w3c.github.io/wpub/, that the processing does not happen and one has to reload the page. It may be a race condition, and it may be related. |
Will try to take a look tomorrow. If you can capture any console errors or steps to reproduce, that's hugely helpful. |
I've been having the problem in Chrome, with the result of only a partial load. Here's what I've been getting in the console:
|
Sent a PR to run ReSpec sync. That should hopefully put things in the right order. I'll look around ReSpec's code base for other race conditions. About Firefox - I'm not sure what it might be... it could be a you are hitting an IndexedDB bug in Firefox 55 (that is fixed in 56, but won't be out for about 5 weeks) that sometimes shows up. I'll see if I can get Firefox to break and add any error recovery code. |
did a couple of thousand runs of ReSpec's test suite randomizing async/defer/sync on tests across Safari, Chrome, and Firefox (cache enabled and disabled), but was still unable to get it to crash or throw any errors :( |
Can you reproduce the issue described in https://github.com/w3c/respec/issues/1345#issuecomment-319966645, however? |
That PR did not make the FF problem disappear. Your other advice (in the comment) to use |
No :( But I at least I'm pretty sure of where it's happening (in core/base-runner, as it's the only place where
I can only think what is happening is that somehow ReSpec is running before the script that declares |
If this comes up again for any URLs, please let me know. I'll keep this bug open for a few weeks. On a positive note, it gave me an opportunity to rewrite some aspects of ReSpec and fixed some smaller bugs along the way. |
There was a new pull request[1] yesterday. This time both the master branch and the branch to be merged use the [1] w3c/wpub#43 |
closing, as it hasn't come up again 🤞. |
PR Preview is getting a bunch of issues building (certain) ReSpec-based specs.
PR Preview relies on the spec-generator web service, which itself relies on https://github.com/w3c/respec/blob/develop/tools/respecDocWriter.js.
Unfortunately, the only error spec-generator manages to surface is "😱 ReSpec error: null" which seems to relate to the following seemingly race-condition-induced error I sometimes get when seeing this spec in a browser:
This maybe comes from a missing async attribute when linking to ReSpec? See the source code: https://github.com/w3c/pwpub/blob/c4d7ea649dda01672d5e218cf97d6e1d28edcf2b/index.html.
What I don't know however, is whether all ReSpec specs that don't build have this issue, or if there are multiple issues.
For example, https://github.com/w3c/payment-handler/blob/gh-pages/index.html never seems to build either and is also missing the async attribute.
The only way to find out at scale would be to have better error reporting.
And it seems the trick here would be to maybe wait for a few more errors before aborting respecDocWriter (around here).
Thoughts? Ideas about what the underlying issue is, etc. welcomed.
/cc @deniak, @iherman
The text was updated successfully, but these errors were encountered: