projectLEMDO / lemdoIssues

Repository for LEMDO issue tracking and related documents.
MIT License
1 stars 0 forks source link

Unnecessary appendix listings are being included in edition files #170

Closed martindholmes closed 1 year ago

martindholmes commented 1 year ago

Yesterday I wrote a little diagnostic file to check all the internal links in a generated anthology site. I was astonished to discover there were many broken links in apparently-functional site, and the reason for this -- as well as the reason we're not noticing it -- is that most are in invisible appendix material which has been imported into edition files when it's not needed. I think this is limited to bibl items but I'm not sure yet. It appears in the standalone XML version, so the problem is probably in standalone_import_module.xsl. I'm marking this urgent because a) it increases the file-size of edition files unnecessarily, and b) it produces a lot of broken link errors that are not really a problem for the output but make it harder to find and diagnose any real broken links.

martindholmes commented 1 year ago

I believe this results from the fact that the list of relatedItems in the header of the file is treated as an additional set of sources for appendix items. I don't know why this was done.

martindholmes commented 1 year ago

Fix committed in issue #13797. This fixes it for edition files, but we need to look out for other types of file that might have the same problem.

martindholmes commented 1 year ago

This fixed a few of the issues, but lots remain. More investigation to do here.

martindholmes commented 1 year ago

This is in fact not fixed for edition files, apparently. I'm still seeing full annotation and collation data included in the appendix of an edition file even when the annotation and collation files themselves are not actually linked from the edition file content, just part of the relatedItem collection.

martindholmes commented 1 year ago

I've discovered the source of this: the process that creates the original XML inserts a relatedItem element with `@type='containingEdition', for some reason I can't remember, and this relatedItem was triggering the import of lots of content into edition files. I've now added a fix for that in rev 14047. We'll see if there's any fallout from this. With luck, it will clear enough distractions to make progress possible on the local link-check process for anthology builds.

martindholmes commented 1 year ago

Bad local links in QME are down from over 5,000 to less than a thousand as a result of the last change. It seems likely that many of these are still erroneous, though.

martindholmes commented 1 year ago

I think this is fixed now, and the remaining bad links are the result of #181 or of genuine bad links. Closing this.