Closed pdurbin closed 2 weeks ago
:package: Pushed preview images as
ghcr.io/gdcc/dataverse:10984-returnDatasetFieldTypes
ghcr.io/gdcc/configbaker:10984-returnDatasetFieldTypes
:ship: See on GHCR. Use by referencing with full name as printed above, mind the registry name.
As expected https://jenkins.dataverse.org/job/IQSS-Dataverse-Develop-PR/job/PR-10985/1/testReport/edu.harvard.iq.dataverse.api/DataversesIT/testListMetadataBlocks/ failed with this:
1 expectation failed.
JSON path data[0].fields.title.displayOnCreate doesn't match.
Expected: <true>
Actual: null
This is because the "fields" object is empty:
{
"status": "OK",
"data": [
{
"id": 1,
"name": "citation",
"displayName": "Citation Metadata",
"displayOnCreate": true,
"fields": {
}
}
]
}
There are failing tests at https://jenkins.dataverse.org/job/IQSS-Dataverse-Develop-PR/job/PR-10985/5/testReport/ but they are expected. The tests are:
The fix is coming in this PR:
There are failing tests from GitHub Actions from maven_unit_test.yml:
The fix is coming in this PR:
@PaulBoon we're asking about https://demo.dataverse.org specifically. Can you reproduce the bug there and paste a screenshot? Also, Omer and I are both on Zulip if you'd like to join us there: https://dataverse.zulipchat.com
Testing Completed - no issues found during testing. Testing of 10985.docx
What this PR does / why we need it:
We should be checking for inheritance of metadata blocks from parent collection to child collection.
Which issue(s) this PR closes:
Special notes for your reviewer:
@pdurbin started this pull request but @GPortas added the actual fix.
We were attempting to retrieve the metadata block fields for the requested dataverse without verifying whether isMetadataBlockRoot was set to true. See https://github.com/IQSS/dataverse/pull/10985/files#diff-171c256be8744ca0742a9570ed33a3e335eae0544d08be04545ef31fdd5328d1. Consequently, when accessing a dataverse that inherits from the root, we couldn't find a relationship with the desired metadata block, as that relationship with the block exists in the parent, not the child dataverse.
We have fixed this to always get the fields from the parent collection when isMetadataBlockRoot is false.
Suggestions on how to test this:
Make sure Jenkins reports all test passing.
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?:
No. In practice, this only affects the SPA, which is still in development.
Additional documentation:
None.