eclipse-pass / main

Catch all repository against which issues of general, cross cutting topics are logged.
Apache License 2.0
4 stars 8 forks source link

DOI manuscript retrieval service returns not useful entries #1053

Closed markpatton closed 1 month ago

markpatton commented 2 months ago

What?

The /doi/manuscript endpint sometimes returns entries with empty values that can't be used.

For example:

curl -u backend:backend  -H "X-XSRF-TOKEN:moo" -H "Cookie:XSRF-TOKEN=moo" localhost:8080/doi/manuscript?doi=10.3352/jeehp.2013.10.3
{
  "manuscripts": [
    {
      "url": null,
      "repositoryLabel": null,
      "type": "application/pdf",
      "source": "Unpaywall",
      "name": null,
      "isBest": true
    },
    {
      "url": null,
      "repositoryLabel": "PubMed Central - Europe PMC",
      "type": "application/pdf",
      "source": "Unpaywall",
      "name": null,
      "isBest": false
    },
    {
      "url": null,
      "repositoryLabel": null,
      "type": "application/pdf",
      "source": "Unpaywall",
      "name": null,
      "isBest": false
    },
    {
      "url": "http://pdfs.semanticscholar.org/f594/5cc11565b2389ab95ff9f97baf3a87967d00.pdf",
      "repositoryLabel": null,
      "type": "application/pdf",
      "source": "Unpaywall",
      "name": "5cc11565b2389ab95ff9f97baf3a87967d00.pdf",
      "isBest": false
    }
  ]
}

Note all these entries with null values that cannot be used.

Why?

The service should only return entries which could be used.

How?

Acceptance Criteria

Related Issues

dkriethof commented 2 months ago

@markpatton is this a user-facing issue? (i.e., should we prioritize or can it wait?)

markpatton commented 2 months ago

@dkriethof It looks like the UI is good about ignoring empty entries and does not show them, but this is important to take a look at it becuase it might indicate a worse problem.

markpatton commented 1 month ago

Also noticing that params are added to the filename of the manuscript, which they should not be.

markpatton commented 1 month ago

See https://github.com/eclipse-pass/pass-core/pull/94