jwulf / press-star

A node-based implementation of the popular Death Star authoring environment for PressGang / Docbook
4 stars 1 forks source link

Rebuild fails on press-star but succeeds with local csprocessor run. #42

Closed xsgordon closed 11 years ago

xsgordon commented 11 years ago

I had a rebuild fail with the stack trace shown below from csprocessor (stay with me here):

Starting first validation pass...
Attempting to download all the latest topics...
Attempting to download all the revision topics...
    Downloading revision topics 50% Done
    Downloading revision topics 100% Done
Starting second validation pass...
INFO:  The Content Specification is valid.

Starting to build...
Doing en-US Populate Database Pass
Doing Fixed URL Pass
org.jboss.resteasy.client.ClientResponseFailure: Error status 400 Bad Request returned
    at org.jboss.resteasy.client.core.BaseClientResponse.createResponseFailure(BaseClientResponse.java:523)
    at org.jboss.resteasy.client.core.BaseClientResponse.createResponseFailure(BaseClientResponse.java:514)
    at org.jboss.resteasy.client.core.BaseClientResponse.checkFailureStatus(BaseClientResponse.java:508)
    at org.jboss.resteasy.client.core.extractors.BodyEntityExtractor.extractEntity(BodyEntityExtractor.java:38)
    at org.jboss.resteasy.client.core.ClientInvoker.invoke(ClientInvoker.java:120)
    at org.jboss.resteasy.client.core.ClientProxy.invoke(ClientProxy.java:88)
    at com.sun.proxy.$Proxy27.updateJSONTopics(Unknown Source)
    at com.redhat.contentspec.builder.DocbookBuilder.setFixedURLsPass(DocbookBuilder.java:3808)
    at com.redhat.contentspec.builder.DocbookBuilder.doPopulateDatabasePass(DocbookBuilder.java:661)
    at com.redhat.contentspec.builder.DocbookBuilder.buildBook(DocbookBuilder.java:433)
    at com.redhat.contentspec.builder.DocbookBuilder.buildBook(DocbookBuilder.java:307)
    at com.redhat.contentspec.builder.ContentSpecBuilder.buildBook(ContentSpecBuilder.java:86)
    at com.redhat.contentspec.client.commands.BuildCommand.process(BuildCommand.java:542)
    at com.redhat.contentspec.client.Client.processArgs(Client.java:245)
    at com.redhat.contentspec.client.Client.main(Client.java:109)

Doing en-US First topic pass
    Processing 203 Topics
org.w3c.dom.DOMException: INVALID_CHARACTER_ERR: An invalid or illegal XML character is specified. 
    at org.apache.xerces.dom.CoreDocumentImpl.createEntityReference(Unknown Source)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.restoreEntities(XMLUtilities.java:322)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.restoreEntities(XMLUtilities.java:245)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.restoreEntities(XMLUtilities.java:245)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.restoreEntities(XMLUtilities.java:245)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.restoreEntities(XMLUtilities.java:245)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.restoreEntities(XMLUtilities.java:245)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.restoreEntities(XMLUtilities.java:245)
    at org.jboss.pressgang.ccms.utils.common.XMLUtilities.convertStringToDocument(XMLUtilities.java:419)
    at com.redhat.contentspec.builder.DocbookBuilder.doTopicPass(DocbookBuilder.java:1206)
    at com.redhat.contentspec.builder.DocbookBuilder.doPopulateDatabasePass(DocbookBuilder.java:699)
    at com.redhat.contentspec.builder.DocbookBuilder.buildBook(DocbookBuilder.java:433)
    at com.redhat.contentspec.builder.DocbookBuilder.buildBook(DocbookBuilder.java:307)
    at com.redhat.contentspec.builder.ContentSpecBuilder.buildBook(ContentSpecBuilder.java:86)
    at com.redhat.contentspec.client.commands.BuildCommand.process(BuildCommand.java:542)
    at com.redhat.contentspec.client.Client.processArgs(Client.java:245)
    at com.redhat.contentspec.client.Client.main(Client.java:109)

ERROR: Internal processing error!

Content Spec build task exited with error: 3
Building exited with error:  3
Build job finished 3```

The reason I am filing this as a **press-star** bug is that when I run the build/assembly locally while I get this stack trace the assembly continues after this point and gives me a nice human readable error in the Errors.xml chapter indicating that the issue was:

ERROR: This topic doesn't have well-formed xml. INVALID_CHARACTER_ERR: An invalid or illegal XML character is specified. The processed XML is



I think the same should be (and possibly even was) the case on **press-star** but the fact that there is output on **stderr** is causing it to stop listening and therefore to treat the rebuild as completely failed (thus instead of the "updates available" message you get "rebuild failed" and a link to the log on the UI) rather than using the return code).
jwulf commented 11 years ago

A couple of questions:

  1. Which Spec ID is this, so that I can reproduce;
  2. What version of cspclient are you running locally?
xsgordon commented 11 years ago
  1. 15807, but I have already fixed the issue (was a numeric entity code &034; or something like that.
  2. CSProcessor client version: 0.32.3
jwulf commented 11 years ago

I've updated the csprocessor on the server to 0.32.3 - it was 0.31 previously.

I should have tried a reproducer before I did that. I can't reproduce it with &034; in a topic. Imma close this issue. Please reopen if it occurs again.