Change decision letter parsing for eLife articles. #224
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Re issue https://github.com/elifesciences/issues/issues/6463
A short summary of the bug to be fixed in this PR, eLife Decision letter and Author response
<sub-article>
peer review articles previously had@id
attribute values ofSA1
andSA2
, and these were used in the query selectors in Lens'elife_converter.js
to find them.In more recent eLife articles the
@id
values have gone lowercase,sa1
andsa2
, which causes them to not display on Lens.Initially we were planning to change the logic to look at the
@article-type
of the<sub-article>
tag to determine whether the node should be assigned a heading of "Decision letter" or "Author response". After some consideration of how the<sub-article>
tags could be processed in a loop, it looked to be easier to take the Lens node heading value from the<article-title>
tag of the<sub-article>
.This should only affect eLife articles since we are only editing the
converter/elife_converter.js
file. The logic here should also be backwards compatible for all eLife articles based on the previously published article data I checked. It also does not cause any errors if there are no<sub-article>
tags in the article XML.