Include contributors with includeInCitation=True as DataCite creators#398
Open
yarikoptic wants to merge 1 commit intomasterfrom
Open
Include contributors with includeInCitation=True as DataCite creators#398yarikoptic wants to merge 1 commit intomasterfrom
yarikoptic wants to merge 1 commit intomasterfrom
Conversation
Previously, only contributors with dcite:Author role were placed into DataCite creators. Organizations (e.g., "Allen Institute for Brain Science" in dandiset 000020) that had includeInCitation=True but no dcite:Author role ended up only as DataCite contributors with contributorType "Other" -- despite appearing in the citation string. Now any contributor with includeInCitation=True OR dcite:Author role becomes a DataCite creator. Tests: folded new includeInCitation test cases into the existing test_dandimeta_datacite parametric test. Removed @skipif_no_doi_prefix and @skipif_no_datacite_auth decorators so that local validation (schema + field checks) always runs; posting to DataCite is now gated at runtime on credential availability. This required adapting the publisher field check to be instance-config-aware (via _EXPECTED_PUBLISHER) since the RRID fields are only present for the DANDI instance, not DANDI-ADHOC. Co-Authored-By: Claude Code 2.1.107 / Claude Opus 4.6 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #398 +/- ##
==========================================
- Coverage 97.92% 97.88% -0.04%
==========================================
Files 18 18
Lines 2405 2410 +5
==========================================
+ Hits 2355 2359 +4
- Misses 50 51 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Member
|
Some tests are still failing, particularly ones that have vendor specific information. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Previously, only contributors with dcite:Author role were placed into DataCite creators. Organizations (e.g., "Allen Institute for Brain Science" in dandiset 000020) that had includeInCitation=True but no dcite:Author role ended up only as DataCite contributors with contributorType "Other" -- despite appearing in the citation string.
Now any contributor with includeInCitation=True OR dcite:Author role becomes a DataCite creator.
Tests: folded new includeInCitation test cases into the existing test_dandimeta_datacite parametric test. Removed @skipif_no_doi_prefix and @skipif_no_datacite_auth decorators so that local validation (schema + field checks) always runs; posting to DataCite is now gated at runtime on credential availability. This required adapting the publisher field check to be instance-config-aware (via _EXPECTED_PUBLISHER) since the RRID fields are only present for the DANDI instance, not DANDI-ADHOC.
This is initially triggered by curation work on https://github.com/bids-dandisets/curations/ and running into empty Authors within https://github.com/bids-dandisets/000020/blob/curation/dataset_description.json#L7 .
Related issues/PRs now