Skip to content

give files a resourceTypeGeneral of "Other" instead of "Dataset" for the DataCite PID provider - #12713

Open
pdurbin wants to merge 4 commits into
developfrom
12476-files-as-other
Open

pdurbin wants to merge 4 commits into
developfrom
12476-files-as-other

Conversation

@pdurbin

@pdurbin pdurbin commented Sep 16, 2026 •

Copy link
Copy Markdown
Member

What this PR does / why we need it:

Data files are not datasets. For now, we are going to send DataCite "resourceTypeGeneral=Other" for data files instead of "Dataset". Longer term, we plan to work in DataCite to come up with a better term than "Other" for data files. There is discussion in the following thread about that:

Which issue(s) this PR closes:

Special notes for your reviewer:

I added a line to the docs at https://dataverse-guide--12713.org.readthedocs.build/en/12713/installation/config.html#filepidsenabled about "Other" and a line to the following issue for more context:

While I was in there, I noticed the nearby curl commands have extra `` around them. I'm happy to fix this. Please let me know.

I left a comment about the upgrade step.

There's no way to see the file-level DataCite XML via API. Perhaps we should add one. For now, I added the ability to log this XML.

Suggestions on how to test this:

  • Enable file PIDS: curl -X PUT -d 'true' http://localhost:8080/api/admin/settings/:FilePIDsEnabled
  • For your PID provider, use DataCite test settings (see below)
  • Create a dataset, upload a file
  • Log into DataCite Fabrica Test at https://doi.test.datacite.org and make sure the file you uploaded shows "Other" rather than "Dataset". See the before and after screenshots below.
  • Also from Fabrica Test, in the DataCite XML for the file, you can look for <resourceType resourceTypeGeneral="Other"/> as in the screenshot below.
  • You can also increase logging to see the log message below.

Before

Screenshot 2026-09-22 at 2 36 58 PM

After

Screenshot 2026-09-22 at 2 37 05 PM Screenshot 2026-09-22 at 2 43 07 PM

Suggested settings

-Ddataverse.pid.providers=dc1
-Ddataverse.pid.default-provider=dc1
-Ddataverse.pid.dc1.type=datacite
-Ddataverse.pid.dc1.label=DataCite
-Ddataverse.pid.dc1.authority=10.70122
-Ddataverse.pid.dc1.shoulder=FK2/
-Ddataverse.pid.dc1.datacite.mds-api-url=https://mds.test.datacite.org
-Ddataverse.pid.dc1.datacite.rest-api-url=https://api.test.datacite.org
-Ddataverse.pid.dc1.datacite.username=REDACTED
-Ddataverse.pid.dc1.datacite.password=REDACTED

Logging (if turned up from fine to info):

[#|2026-09-22T19:40:38.816+0000|INFO|Payara 7.2026.8|edu.harvard.iq.dataverse.pidproviders.doi.datacite.DataCiteRESTfullClient|_ThreadID=322;_ThreadName=__ejb-thread-pool15;_TimeMillis=1790106038816;_LevelValue=800;|
  XML to send to DataCite:
<?xml version="1.0" encoding="UTF-8"?>
<resource xmlns="http://datacite.org/schema/kernel-4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://datacite.org/schema/kernel-4 http://schema.datacite.org/meta/kernel-4.7/metadata.xsd">
  <identifier identifierType="DOI">10.70122/FK2/Y1HL8A/UL8WS3</identifier>
  <creators>
    <creator>
      <creatorName nameType="Personal">Admin, Dataverse</creatorName>
      <givenName>Dataverse</givenName>
      <familyName>Admin</familyName>
      <affiliation>Dataverse.org</affiliation>
    </creator>
  </creators>
  <titles>
    <title>wolf.jpeg</title>
  </titles>
  <publisher>Root</publisher>
  <publicationYear>2026</publicationYear>
  <dates>
    <date dateType="Available">2026-09-22</date>
  </dates>
  <resourceType resourceTypeGeneral="Other"/>
  <relatedIdentifiers>
    <relatedIdentifier relationType="IsPartOf" relatedIdentifierType="DOI">10.70122/FK2/Y1HL8A</relatedIdentifier>
  </relatedIdentifiers>
  <sizes>
    <size>23846</size>
  </sizes>
  <formats>
    <format>image/jpeg</format>
  </formats>
  <version>2.0</version>
  <rightsList>
    <rights rightsURI="info:eu-repo/semantics/openAccess"/>
    <rights rightsURI="http://creativecommons.org/publicdomain/zero/1.0" rightsIdentifier="CC0-1.0" rightsIdentifierScheme="SPDX" schemeURI="https://spdx.org/licenses/" xml:lang="en">Creative Commons CC0 1.0 Universal Public Domain Dedication.</rights>
  </rightsList>
</resource>
|#]

Does this PR introduce a user interface change? If mockups are available, please link/include them here:

No.

Is there a release notes update needed for this change?:

Yes, included.

Additional documentation:

None.

@coveralls

coveralls commented Sep 16, 2026 •

Copy link
Copy Markdown

Coverage Status

coverage: 25.524% (+0.09%) from 25.438% — 12476-files-as-other into develop

@github-actions

github-actions Bot commented Sep 16, 2026 •

Copy link
Copy Markdown

Test Results

406 tests  ±0   391 ✅ ±0   31m 16s ⏱️ + 9m 21s
 55 suites ±0    15 💤 ±0 
 55 files   ±0     0 ❌ ±0 

Results for commit 1e83394. ± Comparison against base commit ee8bf0b.

♻️ This comment has been updated with latest results.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

If you are using DataCite as a Persistent ID provider and have files that have DOIs, you may want to update their metadata records to pick up the change from "Dataset" to "Other" for resourceTypeGeneral (see #12713).

We recommend experimenting with a single dataset first (see [docs](https://guides.dataverse.org/en/6.13/admin/dataverses-datasets.html#update-metadata-for-a-published-dataset-at-the-pid-provider)). Depending on how many DOIs need to be changed, you might want to iterate though datasets one by one but an API endpoint is available to process all datasets at once (see [docs](https://guides.dataverse.org/en/6.13/admin/dataverses-datasets.html#update-metadata-for-all-published-datasets-at-the-pid-provider)).

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If people prefer the following version from https://github.com/IQSS/dataverse/releases/tag/v6.5 I'm happy to switch to it:

Image

@github-actions

This comment has been minimized.

@pdurbin pdurbin moved this from In Progress 💻 to Ready for Review ⏩ in IQSS Dataverse Project Sep 22, 2026
@pdurbin pdurbin removed their assignment Sep 22, 2026
@pdurbin pdurbin changed the title give files a resourceTypeGeneral of "Other" give files a resourceTypeGeneral of "Other" instead of "Dataset" for the DataCite PID provider Sep 22, 2026
@github-actions

This comment has been minimized.

@cmbz cmbz added FY27 Sprint 6 FY27 Sprint 6 (2026-09-09 - 2026-09-23) FY27 Sprint 7 FY27 Sprint 7 (2026-09-23 - 2026-10-07) labels Sep 23, 2026
@pdurbin
pdurbin force-pushed the 12476-files-as-other branch from e38241f to 1e83394 Compare September 29, 2026 18:51
@sonarqubecloud

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
60.0% Coverage on New Code (required ≥ 80%)

See analysis details on SonarQube Cloud

@github-actions

Copy link
Copy Markdown

📦 Pushed preview images as

ghcr.io/gdcc/dataverse:12476-files-as-other
ghcr.io/gdcc/configbaker:12476-files-as-other

🚢 See on GHCR. Use by referencing with full name as printed above, mind the registry name.

This branch has not been deployed

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

Labels

Feature: Metadata Feature: Metrics + Reports FY27 Roadmap FY27 Sprint 6 FY27 Sprint 6 (2026-09-09 - 2026-09-23) FY27 Sprint 7 FY27 Sprint 7 (2026-09-23 - 2026-10-07) GREI Year 5 GREI 4 Analytics and Reporting Original size: 20 Type: Feature a feature request

Projects

Status: Ready for Review ⏩

3 participants