From 24ac1dd2f0783583881320ef5fde6540d8530467 Mon Sep 17 00:00:00 2001 From: Martin Czygan Date: Thu, 9 Jan 2020 02:02:37 +0100 Subject: datacite: get rid of schemaVersion --- python/fatcat_tools/importers/datacite.py | 3 --- python/tests/files/datacite/datacite_result_00.json | 3 +-- python/tests/files/datacite/datacite_result_01.json | 3 +-- python/tests/files/datacite/datacite_result_02.json | 3 +-- python/tests/files/datacite/datacite_result_03.json | 4 +--- python/tests/files/datacite/datacite_result_04.json | 3 +-- python/tests/files/datacite/datacite_result_05.json | 3 +-- python/tests/files/datacite/datacite_result_06.json | 3 +-- python/tests/files/datacite/datacite_result_09.json | 1 - python/tests/files/datacite/datacite_result_10.json | 1 - python/tests/files/datacite/datacite_result_11.json | 3 +-- python/tests/files/datacite/datacite_result_13.json | 3 +-- python/tests/files/datacite/datacite_result_14.json | 1 - python/tests/files/datacite/datacite_result_15.json | 3 +-- python/tests/files/datacite/datacite_result_16.json | 3 +-- python/tests/files/datacite/datacite_result_17.json | 3 +-- python/tests/files/datacite/datacite_result_18.json | 3 +-- python/tests/files/datacite/datacite_result_19.json | 3 +-- 18 files changed, 14 insertions(+), 35 deletions(-) (limited to 'python') diff --git a/python/fatcat_tools/importers/datacite.py b/python/fatcat_tools/importers/datacite.py index b1862b44..7878ebfa 100644 --- a/python/fatcat_tools/importers/datacite.py +++ b/python/fatcat_tools/importers/datacite.py @@ -559,12 +559,9 @@ class DataciteImporter(EntityImporter): # Include version information. metadata_version = attributes.get('metadataVersion') or '' - schema_version = attributes.get('schemaVersion') or '' if metadata_version: extra_datacite['metadataVersion'] = metadata_version - if schema_version: - extra_datacite['schemaVersion'] = schema_version # Include resource types. types = attributes.get('types', {}) or {} diff --git a/python/tests/files/datacite/datacite_result_00.json b/python/tests/files/datacite/datacite_result_00.json index 89450f9d..06147cfc 100644 --- a/python/tests/files/datacite/datacite_result_00.json +++ b/python/tests/files/datacite/datacite_result_00.json @@ -37,8 +37,7 @@ } ], "resourceType": "JournalArticle", - "resourceTypeGeneral": "Text", - "schemaVersion": "http://datacite.org/schema/kernel-4" + "resourceTypeGeneral": "Text" }, "release_month": 5 }, diff --git a/python/tests/files/datacite/datacite_result_01.json b/python/tests/files/datacite/datacite_result_01.json index 9fc62db4..1b796e7c 100644 --- a/python/tests/files/datacite/datacite_result_01.json +++ b/python/tests/files/datacite/datacite_result_01.json @@ -22,8 +22,7 @@ ], "metadataVersion": 4, "resourceType": "DigitalisatDigital copy", - "resourceTypeGeneral": "Text", - "schemaVersion": "http://datacite.org/schema/kernel-4" + "resourceTypeGeneral": "Text" } }, "language": "fr", diff --git a/python/tests/files/datacite/datacite_result_02.json b/python/tests/files/datacite/datacite_result_02.json index d6b9556f..d4b62262 100644 --- a/python/tests/files/datacite/datacite_result_02.json +++ b/python/tests/files/datacite/datacite_result_02.json @@ -26,8 +26,7 @@ ], "metadataVersion": 2, "resourceType": "DigitalisatDigital copy", - "resourceTypeGeneral": "Text", - "schemaVersion": "http://datacite.org/schema/kernel-4" + "resourceTypeGeneral": "Text" } }, "language": "de", diff --git a/python/tests/files/datacite/datacite_result_03.json b/python/tests/files/datacite/datacite_result_03.json index 6aa65aee..ce120775 100644 --- a/python/tests/files/datacite/datacite_result_03.json +++ b/python/tests/files/datacite/datacite_result_03.json @@ -11,9 +11,7 @@ "doi": "10.13140/rg.2.2.30434.53446" }, "extra": { - "datacite": { - "schemaVersion": "http://datacite.org/schema/kernel-3" - } + "datacite": {} }, "language": "ms", "refs": [], diff --git a/python/tests/files/datacite/datacite_result_04.json b/python/tests/files/datacite/datacite_result_04.json index 571c3f64..df18588c 100644 --- a/python/tests/files/datacite/datacite_result_04.json +++ b/python/tests/files/datacite/datacite_result_04.json @@ -22,8 +22,7 @@ "datacite": { "metadataVersion": 5, "resourceType": "Text", - "resourceTypeGeneral": "Text", - "schemaVersion": "http://datacite.org/schema/kernel-3" + "resourceTypeGeneral": "Text" } }, "language": "en", diff --git a/python/tests/files/datacite/datacite_result_05.json b/python/tests/files/datacite/datacite_result_05.json index 5b7b4ed2..79c2a8fb 100644 --- a/python/tests/files/datacite/datacite_result_05.json +++ b/python/tests/files/datacite/datacite_result_05.json @@ -524,8 +524,7 @@ ], "metadataVersion": 1, "resourceType": "Dataset/UNITE Species Hypothesis", - "resourceTypeGeneral": "Dataset", - "schemaVersion": "http://datacite.org/schema/kernel-3" + "resourceTypeGeneral": "Dataset" }, "release_month": 10 }, diff --git a/python/tests/files/datacite/datacite_result_06.json b/python/tests/files/datacite/datacite_result_06.json index 4f6cae94..32c09b33 100644 --- a/python/tests/files/datacite/datacite_result_06.json +++ b/python/tests/files/datacite/datacite_result_06.json @@ -18,8 +18,7 @@ } ], "metadataVersion": 1, - "resourceTypeGeneral": "InteractiveResource", - "schemaVersion": "http://datacite.org/schema/kernel-3" + "resourceTypeGeneral": "InteractiveResource" } }, "refs": [], diff --git a/python/tests/files/datacite/datacite_result_09.json b/python/tests/files/datacite/datacite_result_09.json index 79571360..09e02fc7 100644 --- a/python/tests/files/datacite/datacite_result_09.json +++ b/python/tests/files/datacite/datacite_result_09.json @@ -28,7 +28,6 @@ "metadataVersion": 9, "resourceType": "Report", "resourceTypeGeneral": "Text", - "schemaVersion": "http://datacite.org/schema/kernel-4", "subjects": [ { "subject": "Direktdiodenlasersysteme" diff --git a/python/tests/files/datacite/datacite_result_10.json b/python/tests/files/datacite/datacite_result_10.json index 1d39feb0..1bb70be6 100644 --- a/python/tests/files/datacite/datacite_result_10.json +++ b/python/tests/files/datacite/datacite_result_10.json @@ -14,7 +14,6 @@ "datacite": { "resourceType": "Dataset", "resourceTypeGeneral": "Dataset", - "schemaVersion": "http://datacite.org/schema/kernel-4", "subjects": [ { "subject": "housing areas" diff --git a/python/tests/files/datacite/datacite_result_11.json b/python/tests/files/datacite/datacite_result_11.json index 761a99c9..7b971aa7 100644 --- a/python/tests/files/datacite/datacite_result_11.json +++ b/python/tests/files/datacite/datacite_result_11.json @@ -13,8 +13,7 @@ "extra": { "datacite": { "metadataVersion": 6, - "resourceTypeGeneral": "Image", - "schemaVersion": "http://datacite.org/schema/kernel-3" + "resourceTypeGeneral": "Image" } }, "language": "de", diff --git a/python/tests/files/datacite/datacite_result_13.json b/python/tests/files/datacite/datacite_result_13.json index 923f2ea8..669425f0 100644 --- a/python/tests/files/datacite/datacite_result_13.json +++ b/python/tests/files/datacite/datacite_result_13.json @@ -21,8 +21,7 @@ "datacite": { "metadataVersion": 17, "resourceType": "Journal Article", - "resourceTypeGeneral": "Text", - "schemaVersion": "http://datacite.org/schema/kernel-3" + "resourceTypeGeneral": "Text" }, "release_month": 10 }, diff --git a/python/tests/files/datacite/datacite_result_14.json b/python/tests/files/datacite/datacite_result_14.json index 2ce68d29..4b5de1e4 100644 --- a/python/tests/files/datacite/datacite_result_14.json +++ b/python/tests/files/datacite/datacite_result_14.json @@ -78,7 +78,6 @@ } ], "resourceTypeGeneral": "Dataset", - "schemaVersion": "http://datacite.org/schema/kernel-3", "subjects": [ { "subject": "Crystal Structure" diff --git a/python/tests/files/datacite/datacite_result_15.json b/python/tests/files/datacite/datacite_result_15.json index 5e7180c4..9dbb9e98 100644 --- a/python/tests/files/datacite/datacite_result_15.json +++ b/python/tests/files/datacite/datacite_result_15.json @@ -16,8 +16,7 @@ "datacite": { "metadataVersion": 1, "resourceType": "dataPackage", - "resourceTypeGeneral": "Dataset", - "schemaVersion": "http://datacite.org/schema/kernel-2.2" + "resourceTypeGeneral": "Dataset" } }, "publisher": "Environmental Data Initiative", diff --git a/python/tests/files/datacite/datacite_result_16.json b/python/tests/files/datacite/datacite_result_16.json index dc9d18af..ad585e3c 100644 --- a/python/tests/files/datacite/datacite_result_16.json +++ b/python/tests/files/datacite/datacite_result_16.json @@ -21,8 +21,7 @@ } ], "resourceType": "Paper", - "resourceTypeGeneral": "Dataset", - "schemaVersion": "http://datacite.org/schema/kernel-3" + "resourceTypeGeneral": "Dataset" } }, "publisher": "Figshare", diff --git a/python/tests/files/datacite/datacite_result_17.json b/python/tests/files/datacite/datacite_result_17.json index 0f768179..ca4e2743 100644 --- a/python/tests/files/datacite/datacite_result_17.json +++ b/python/tests/files/datacite/datacite_result_17.json @@ -12,8 +12,7 @@ }, "extra": { "datacite": { - "resourceTypeGeneral": "Dataset", - "schemaVersion": "http://datacite.org/schema/kernel-4" + "resourceTypeGeneral": "Dataset" } }, "publisher": "Harvard Dataverse", diff --git a/python/tests/files/datacite/datacite_result_18.json b/python/tests/files/datacite/datacite_result_18.json index 7f2d2792..c62f3883 100644 --- a/python/tests/files/datacite/datacite_result_18.json +++ b/python/tests/files/datacite/datacite_result_18.json @@ -6,8 +6,7 @@ }, "extra": { "datacite": { - "metadataVersion": 2, - "schemaVersion": "http://datacite.org/schema/kernel-3" + "metadataVersion": 2 }, "release_month": 8 }, diff --git a/python/tests/files/datacite/datacite_result_19.json b/python/tests/files/datacite/datacite_result_19.json index 4ff00a56..6fbef9cf 100644 --- a/python/tests/files/datacite/datacite_result_19.json +++ b/python/tests/files/datacite/datacite_result_19.json @@ -6,8 +6,7 @@ }, "extra": { "datacite": { - "metadataVersion": 3, - "schemaVersion": "http://datacite.org/schema/kernel-3" + "metadataVersion": 3 }, "release_month": 8 }, -- cgit v1.2.3