Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ORCID does not provide put-codes anymore in the website #1764

Merged
merged 3 commits into from Oct 12, 2018

Conversation

@zuphilip
Copy link
Collaborator

commented Oct 11, 2018

We need now first an API call to receive the put-codes,
with which we then can do calls for an individual work
in CSL-JSON.

Fix issue reported https://forums.zotero.org/discussion/74029/problem-to-download-publictions-from-orcid-to-zotero

ORCID does not provide put-codes anymore
We need now first an API call to receive the put-codes,
with which we then can do calls for an individual work
in CSL-JSON.

@zuphilip zuphilip requested a review from adam3smith Oct 11, 2018

@zuphilip zuphilip changed the title ORCID does not provide put-codes anymore ORCID does not provide put-codes anymore in the website Oct 11, 2018

@adam3smith adam3smith referenced this pull request Oct 12, 2018

Closed

ORCID Translator #1091

@TomDemeranville

This comment has been minimized.

Copy link

commented Oct 12, 2018

Hi Phillipe,

This code will process all of the work summaries for a person using the API, which is great.

However, you may want to consider than some people will have more than one representation of a given work. The ORCID API places these in 'groups' and it can happen if for example a CRIS system, and a publisher both add a work. This means the current code will import duplicates for some people.

An example can be found on my record, where put-code="17080227" and put-code="17080287" are in the same group. You can take a look with curl -X GET --header 'Accept: application/xml' 'https://pub.orcid.org/v2.1/0000-0003-0902-4386/works'

You may want to try using an xpath more like: /activities:works/activities:group/work:work-summary[1] which will only process the first work in each group.

Thanks for keeping this code up to date, we really appreciate it and I'm sure the Zotero users do too!

@adam3smith

This comment has been minimized.

Copy link
Collaborator

commented Oct 12, 2018

@zuphilip -- what Tom says makes sense to me, so see if you can add that. Rest of the code looks good to me, thanks!

@zuphilip

This comment has been minimized.

Copy link
Collaborator Author

commented Oct 12, 2018

@TomDemeranville Thank you for the hint. I will do what you suggest. Just one question: is the first work in each group always equal to the preferred source?

zuphilip and others added some commits Oct 12, 2018

ZU.xpath returns an empty array
which isn't null; test for length

@adam3smith adam3smith merged commit 4873ed6 into zotero:master Oct 12, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@adam3smith

This comment has been minimized.

Copy link
Collaborator

commented Oct 12, 2018

Thanks both!

@zuphilip zuphilip deleted the zuphilip:fix-orcid-2018 branch Oct 13, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.