Skip to content

Commit 9ede0c5

Browse files
authored
Merge pull request #1916 from effigies/enh/citation.cff
fix(schema): Authors is recommended if CITATION.cff is absent
2 parents 5f5f997 + eab2a67 commit 9ede0c5

File tree

2 files changed

+17
-8
lines changed

2 files changed

+17
-8
lines changed

src/modality-agnostic-files.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ and a guide for using macros can be found at
3434
"DatasetLinks": "REQUIRED if [BIDS URIs][] are used",
3535
"DatasetType": "RECOMMENDED",
3636
"License": "RECOMMENDED",
37-
"Authors": "RECOMMENDED",
37+
"Authors": "RECOMMENDED if CITATION.cff is not present",
3838
"Acknowledgements": "OPTIONAL",
3939
"HowToAcknowledge": "OPTIONAL",
4040
"Funding": "OPTIONAL",

src/schema/rules/dataset_metadata.yaml

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,8 @@ dataset_description:
88
DatasetType: recommended
99
License: recommended
1010
Authors:
11-
level: recommended
12-
issue:
13-
code: NO_AUTHORS
14-
message: |
15-
The Authors field of dataset_description.json should contain an array of fields -
16-
with one author per field. This was triggered because there are no authors, which
17-
will make DOI registration from dataset metadata impossible.
11+
level: optional
12+
level_addendum: recommended if no CITATION.cff file is present
1813
Acknowledgements: optional
1914
HowToAcknowledge: optional
2015
Funding: optional
@@ -24,6 +19,20 @@ dataset_description:
2419
GeneratedBy: recommended
2520
SourceDatasets: recommended
2621

22+
dataset_authors:
23+
selectors:
24+
- path == "/dataset_description.json"
25+
- '!exists("CITATION.cff", "dataset")'
26+
fields:
27+
Authors:
28+
level: recommended
29+
issue:
30+
code: NO_AUTHORS
31+
message: |
32+
The Authors field of dataset_description.json should contain an array of fields -
33+
with one author per field. This was triggered because there are no authors, which
34+
will make DOI registration from dataset metadata impossible.
35+
2736
derivative_description:
2837
selectors:
2938
- path == "/dataset_description.json"

0 commit comments

Comments
 (0)