From c3149b5cf3cd46c34893144df8bb328896a27103 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 13:06:13 +0200 Subject: [PATCH 1/9] add small .zenodo.json --- .github/workflows/validate-metadata.yml | 16 ++++++++++++++++ .zenodo.json | 6 ++++++ CONTRIBUTING.md | 6 ++++++ 3 files changed, 28 insertions(+) create mode 100644 .github/workflows/validate-metadata.yml create mode 100644 .zenodo.json diff --git a/.github/workflows/validate-metadata.yml b/.github/workflows/validate-metadata.yml new file mode 100644 index 0000000..fdee2c6 --- /dev/null +++ b/.github/workflows/validate-metadata.yml @@ -0,0 +1,16 @@ +name: Validate JSON + +on: push + +jobs: + validate: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Validate JSON + uses: walbo/validate-json@v1.1.0 + with: + files: .zenodo.json + schema: https://zenodo.org/schemas/deposits/records/legacyrecord.json + fail-on-missing-schema: true + strict: true diff --git a/.zenodo.json b/.zenodo.json new file mode 100644 index 0000000..9c8a445 --- /dev/null +++ b/.zenodo.json @@ -0,0 +1,6 @@ +{ + "title": "EUREC4A Intake catalogue", + "communities": [ + {"identifier": "eurec4a"} + ] +} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index aa01ccf..3295844 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -15,3 +15,9 @@ Please remember to put an entry into our changelog (`CHANGELOG.md`). We are keeping a changelog in the file `CHANGELOG.md`. Every pull request has to add a summary of what it's doing into that file. This description is meant as a high level overview of what has been changed, so it should be quick to read and in particular shouldn't be just a verbatim copy of all the commit messages. Another purpose of the changelog is to help with our process of releasing new versions: we'll have to check how severe the changes introduced since the last version are in order to come up with a sensible new version number. + +## Register you as an author + +Occasionally, a copy of the intake catalog is released via [Zenodo](https://zenodo.org/). +When doing so, we are happy to include you as an author to the repository, but we need some information about you. +If not yet the case, please insert your details into the `.zenodo.json` file. From c1d2aee059a6a79324990e85dfe1767c7320fc88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 13:08:33 +0200 Subject: [PATCH 2/9] schema: try http --- .github/workflows/validate-metadata.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/validate-metadata.yml b/.github/workflows/validate-metadata.yml index fdee2c6..307d530 100644 --- a/.github/workflows/validate-metadata.yml +++ b/.github/workflows/validate-metadata.yml @@ -11,6 +11,6 @@ jobs: uses: walbo/validate-json@v1.1.0 with: files: .zenodo.json - schema: https://zenodo.org/schemas/deposits/records/legacyrecord.json + schema: http://zenodo.org/schemas/deposits/records/legacyrecord.json fail-on-missing-schema: true strict: true From 328a471b58b702994106919289b9f722ee2769ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 13:10:22 +0200 Subject: [PATCH 3/9] schema: try local copy --- .github/workflows/validate-metadata.yml | 2 +- tests/json/legacyrecord.json | 457 ++++++++++++++++++++++++ 2 files changed, 458 insertions(+), 1 deletion(-) create mode 100644 tests/json/legacyrecord.json diff --git a/.github/workflows/validate-metadata.yml b/.github/workflows/validate-metadata.yml index 307d530..50002e5 100644 --- a/.github/workflows/validate-metadata.yml +++ b/.github/workflows/validate-metadata.yml @@ -11,6 +11,6 @@ jobs: uses: walbo/validate-json@v1.1.0 with: files: .zenodo.json - schema: http://zenodo.org/schemas/deposits/records/legacyrecord.json + schema: tests/json/legacyrecord.json fail-on-missing-schema: true strict: true diff --git a/tests/json/legacyrecord.json b/tests/json/legacyrecord.json new file mode 100644 index 0000000..c5561a2 --- /dev/null +++ b/tests/json/legacyrecord.json @@ -0,0 +1,457 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "additionalProperties": false, + "description": "Describe information needed for deposit module.", + "id": "http://zenodo.org/schemas/deposits/records/legacyjson.json", + "properties": { + "$schema": { + "type": "string" + }, + "access_conditions": { + "description": "Conditions under which access is given if record is restricted.", + "title": "Access conditions", + "type": "string" + }, + "access_right": { + "default": "open", + "description": "Access right for record.", + "enum": [ + "open", + "embargoed", + "restricted", + "closed" + ], + "type": "string" + }, + "communities": { + "description": "List of community identifiers.", + "items": { + "additionalProperties": false, + "properties": { + "identifier": { + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "contributors": { + "description": "Contributors in order of importance.", + "items": { + "additionalProperties": false, + "properties": { + "affiliation": { + "description": "Affiliation for the purpose of this specific record.", + "type": "string" + }, + "gnd": { + "description": "Gemeinsame Normdatei identifier for creator.", + "type": "string" + }, + "name": { + "description": "Full name of person or organisation. Personal name format: family, given.", + "type": "string" + }, + "orcid": { + "description": "ORCID identifier for creator.", + "type": "string" + }, + "type": { + "enum": [ + "ContactPerson", + "DataCollector", + "DataCurator", + "DataManager", + "Distributor", + "Editor", + "HostingInstitution", + "Other", + "Producer", + "ProjectLeader", + "ProjectManager", + "ProjectMember", + "RegistrationAgency", + "RegistrationAuthority", + "RelatedPerson", + "ResearchGroup", + "RightsHolder", + "Researcher", + "Sponsor", + "Supervisor", + "WorkPackageLeader" + ], + "type": "string" + } + }, + "type": "object" + }, + "title": "Contributors", + "type": "array" + }, + "creators": { + "description": "Creators of record in order of importance.", + "items": { + "additionalProperties": false, + "properties": { + "affiliation": { + "description": "Affiliation for the purpose of this specific record.", + "type": "string" + }, + "gnd": { + "description": "Gemeinsame Normdatei identifier for creator.", + "type": "string" + }, + "name": { + "description": "Full name of person or organisation. Personal name format: family, given.", + "type": "string" + }, + "orcid": { + "description": "ORCID identifier for creator.", + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "description": { + "description": "Description/abstract for record.", + "type": "string" + }, + "doi": { + "description": "Digital Object Identifier (DOI).", + "type": "string" + }, + "embargo_date": { + "description": "Embargo date of record (ISO8601 formatted date).", + "title": "Embargo Date", + "type": "string" + }, + "grants": { + "description": "Source of grants/awards which have funded all or part of this particular record.", + "items": { + "additionalProperties": false, + "properties": { + "id": { + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "imprint_isbn": { + "type": "string" + }, + "imprint_place": { + "type": "string" + }, + "imprint_publisher": { + "type": "string" + }, + "journal_issue": { + "description": "Journal issue.", + "title": "Journal issue", + "type": "string" + }, + "journal_pages": { + "description": "Journal page(s).", + "title": "Journal page(s)", + "type": "string" + }, + "journal_title": { + "description": "Journal title.", + "title": "Journal title", + "type": "string" + }, + "journal_volume": { + "description": "Journal volume.", + "title": "Journal volume", + "type": "string" + }, + "keywords": { + "description": "Free text keywords.", + "items": { + "title": "Keyword", + "type": "string" + }, + "title": "Keywords", + "type": "array" + }, + "license": { + "description": "License for embargoed/open access content.", + "title": "License", + "type": "string", + "default": "CC-BY-4.0" + }, + "conference_acronym": { + "title": "Acronym", + "type": "string" + }, + "conference_dates": { + "title": "Dates", + "type": "string" + }, + "conference_place": { + "title": "Place", + "type": "string" + }, + "conference_session": { + "title": "Session", + "type": "string" + }, + "conference_session_part": { + "title": "Part of session", + "type": "string" + }, + "conference_title": { + "title": "Title", + "type": "string" + }, + "conference_url": { + "title": "URL", + "type": "string" + }, + "notes": { + "description": "Additional notes for record.", + "title": "Additional notes", + "type": "string" + }, + "partof_pages": { + "title": "Pages", + "type": "string" + }, + "partof_title": { + "title": "Title", + "type": "string" + }, + "publication_date": { + "description": "Record publication date (IS8601-formatted). EDTF support to be added for field.", + "type": "string" + }, + "references": { + "description": "Raw textual references when identifier is not known.", + "items": { + "type": "string" + }, + "type": "array" + }, + "related_identifiers": { + "description": "Related research outputs.", + "items": { + "properties": { + "identifier": { + "description": "Identifier of research output.", + "type": "string" + }, + "relation": { + "description": "Relation type.", + "enum": [ + "isCitedBy", + "cites", + "isSupplementTo", + "isSupplementedBy", + "isContinuedBy", + "continues", + "isDescribedBy", + "describes", + "hasMetadata", + "isMetadataFor", + "isNewVersionOf", + "isPreviousVersionOf", + "isPartOf", + "hasPart", + "isReferencedBy", + "references", + "isDocumentedBy", + "documents", + "isCompiledBy", + "compiles", + "isVariantFormOf", + "isOrignialFormOf", + "isIdenticalTo", + "isAlternateIdentifier", + "isReviewedBy", + "reviews", + "isDerivedFrom", + "isSourceOf", + "requires", + "isRequiredBy", + "isObsoletedBy", + "obsoletes", + "isPublishedIn" + ], + "type": "string" + }, + "scheme": { + "description": "Persistent identifier scheme.", + "enum": [ + "ads", + "ark", + "arrayexpress_array", + "arrayexpress_experiment", + "arxiv", + "ascl", + "bioproject", + "biosample", + "doi", + "ean13", + "ean8", + "ensembl", + "genome", + "geo", + "gnd", + "hal", + "handle", + "isbn", + "isni", + "issn", + "istc", + "lsid", + "orcid", + "pmcid", + "pmid", + "purl", + "refseq", + "ror", + "sra", + "swh", + "uniprot", + "url", + "urn" + ], + "type": "string" + }, + "resource_type": { + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "upload_type": { + "additionalProperties": false, + "default": "publication", + "description": "Record upload type.", + "enum": [ + "publication", + "poster", + "presentation", + "dataset", + "image", + "video", + "software", + "lesson", + "workflow", + "physicalobject", + "other" + ], + "type": "string" + }, + "publication_type": { + "additionalProperties": false, + "description": "Publication type.", + "default": "article", + "enum": [ + "book", + "section", + "conferencepaper", + "article", + "patent", + "preprint", + "report", + "deliverable", + "milestone", + "proposal", + "softwaredocumentation", + "thesis", + "technicalnote", + "workingpaper", + "datamanagementplan", + "annotationcollection", + "taxonomictreatment", + "peerreview", + "other" + ], + "type": "string" + }, + "image_type": { + "additionalProperties": false, + "default": "figure", + "description": "Image type.", + "enum": [ + "figure", + "plot", + "drawing", + "diagram", + "photo", + "other" + ], + "type": "string" + }, + "openaire_type": { + "type": "string", + "description": "OpenAIRE type." + }, + "subjects": { + "description": "Subjects from specific vocabularies.", + "items": { + "additionalProperties": false, + "properties": { + "identifier": { + "description": "Subjects term identifier.", + "type": "string" + }, + "scheme": { + "description": "Identifier scheme.", + "type": "string" + }, + "term": { + "description": "Subject term value.", + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "thesis_supervisors": { + "description": "Supervisors of thesis in order of importance.", + "items": { + "additionalProperties": false, + "properties": { + "affiliation": { + "description": "Affiliation for the purpose of this specific record.", + "type": "string" + }, + "gnd": { + "description": "Gemeinsame Normdatei identifier for creator.", + "type": "string" + }, + "name": { + "description": "Full name of person or organisation. Personal name format: family, given.", + "type": "string" + }, + "orcid": { + "description": "ORCID identifier for creator.", + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "thesis_university": { + "description": "Awarding university in case of a thesis.", + "type": "string" + }, + "title": { + "description": "Record title.", + "type": "string" + } + }, + "title": "Zenodo Legacy Deposit Schema v1.0.0", + "type": "object" +} From 8d623fc1c4fc848fa82a93b27ca9a56480e633d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 13:13:09 +0200 Subject: [PATCH 4/9] schema: non-strict mode (?) --- .github/workflows/validate-metadata.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/validate-metadata.yml b/.github/workflows/validate-metadata.yml index 50002e5..968d66f 100644 --- a/.github/workflows/validate-metadata.yml +++ b/.github/workflows/validate-metadata.yml @@ -13,4 +13,4 @@ jobs: files: .zenodo.json schema: tests/json/legacyrecord.json fail-on-missing-schema: true - strict: true + strict: false From b33c7b13e9f77796e1f7d39d3fcdbe113d84a622 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 13:22:45 +0200 Subject: [PATCH 5/9] zenodo: add access_right: open --- .zenodo.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.zenodo.json b/.zenodo.json index 9c8a445..934d447 100644 --- a/.zenodo.json +++ b/.zenodo.json @@ -2,5 +2,6 @@ "title": "EUREC4A Intake catalogue", "communities": [ {"identifier": "eurec4a"} - ] + ], + "access_right": "open" } From a0ea93d9703cf1d17482e8d85874fb6ca1a5f826 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 13:27:20 +0200 Subject: [PATCH 6/9] zenodo: trigger also on pull_request --- .github/workflows/validate-metadata.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/validate-metadata.yml b/.github/workflows/validate-metadata.yml index 968d66f..67e6eac 100644 --- a/.github/workflows/validate-metadata.yml +++ b/.github/workflows/validate-metadata.yml @@ -1,6 +1,6 @@ name: Validate JSON -on: push +on: [push, pull_request] jobs: validate: From cd9e80521fcc575b24c6d61c4a9973a5c082d865 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 16:22:13 +0200 Subject: [PATCH 7/9] zenodo: add license, upload_type, creators --- .zenodo.json | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.zenodo.json b/.zenodo.json index 934d447..509e9d3 100644 --- a/.zenodo.json +++ b/.zenodo.json @@ -1,7 +1,14 @@ { - "title": "EUREC4A Intake catalogue", + "title": "EUREC4A", "communities": [ {"identifier": "eurec4a"} ], - "access_right": "open" + "access_right": "open", + "license": "cc-zero", + "upload_type": "dataset", + "creators": [ + { + "name": "EUREC4A community" + } + ] } From dee2789a68d331abe981a289c15c99cd9cdd33d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 16:23:21 +0200 Subject: [PATCH 8/9] CONTRIBUTING: remove 'registering as an author' --- CONTRIBUTING.md | 6 ------ 1 file changed, 6 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3295844..aa01ccf 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -15,9 +15,3 @@ Please remember to put an entry into our changelog (`CHANGELOG.md`). We are keeping a changelog in the file `CHANGELOG.md`. Every pull request has to add a summary of what it's doing into that file. This description is meant as a high level overview of what has been changed, so it should be quick to read and in particular shouldn't be just a verbatim copy of all the commit messages. Another purpose of the changelog is to help with our process of releasing new versions: we'll have to check how severe the changes introduced since the last version are in order to come up with a sensible new version number. - -## Register you as an author - -Occasionally, a copy of the intake catalog is released via [Zenodo](https://zenodo.org/). -When doing so, we are happy to include you as an author to the repository, but we need some information about you. -If not yet the case, please insert your details into the `.zenodo.json` file. From 6f9109b44ffc46e55b418ba4f1c064b60a8821c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20Ko=CC=88lling?= Date: Mon, 9 Oct 2023 17:03:27 +0200 Subject: [PATCH 9/9] zenodo: add description and note --- .zenodo.json | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.zenodo.json b/.zenodo.json index 509e9d3..bcee932 100644 --- a/.zenodo.json +++ b/.zenodo.json @@ -1,10 +1,12 @@ { "title": "EUREC4A", + "description": "The catalog describing the EUREC4A dataset.", "communities": [ {"identifier": "eurec4a"} ], "access_right": "open", "license": "cc-zero", + "notes": "The license (CC-0) applies to the dataset catalog. The individual datasets may be subject to different terms. When using the underlying data in publications, please give credit to the individual dataset creators and adhere to the EUREC4A data policy.", "upload_type": "dataset", "creators": [ {