Skip to content

Citation processing progress is counted over structured citations instead of all #13308

Description

@bozana

In citationManagerStore.js, both halves of the processing progress were computed over structuredCitations rather than over all citations:

const totalCitations = computed(() => structuredCitations.value.length);
const processedCitations = computed(() =>
structuredCitations.value.filter(
(citation) => citation?.processingStatus === pkp.const.citationProcessingStatus.PROCESSED,
).length,
);

isStructured is set by the API only once a citation has an identifier (doi, arxiv, handle, url or urn) and a title and authors — see Citation::isStructured().
It is a maybe a reportable number in its own right, but it cannot serve as the total.

Two consequences.
The message is wrong. On a 67-citation publication the UI reported "All 26 references successfully processed" — 26 being the number that happened to be structured at that moment, not the number of references.


PRs:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions