When XML Exporter Doesn’t Work
This morning’s export of XML files from K4 failed to work. No files were exported and a problem was reported in the Terminal window. Unfortunately the error didn’t provide information for tracking down the problem.
Yesterday’s XML exports worked fine. I haven’t moved any files nor changed any of the XML export code. So I assumed that the problem was in the data.
My export command uses a K4 query named XML. So finding the problem Article involved editing the XML query and then attempting a XML export. If the export worked then one of the Articles I didn’t export was the problem. And if it didn’t work then the problem was in an Article in the query.
- In my first query I eliminated all Articles assigned to the main workflow for our current issue and the export worked, so I knew one of the main Articles was at fault.
- I put the main Articles back into the query and used “name begines with” and the name of one of our layouts to see if Articles associated with that layout were the cause of the problem. I kept changing the name in the query until I found the layout asscoiated with the problem Article.
- I then refined the query to eventually isolate the article.
The above approach worked because we use a strict naming convention within K4. If we had random names the above would have taken much longer.
The problem Article had around 100 pictures placed in the text flow so I assume that this was the cause of the problem. Since there was a limited amount of text in this article I decided to move the article backwards in my workflow so it would not be exported and just plan on the pain of creating the XML document by hand via copy and paste. I also asked the design to not place images in the workflow in the future.
And time to put in a bug report to MEI about XML Exporter problems when a text object has images placed directly in them. I suspect it was the number of images placed. We’ve never seen a problem with text boxes placed within a text flow.
But it would have been nice if the log files could have pointed me to the source of problem.