Skip to content

Commit

Permalink
Merge 91b07cd into 1ebf541
Browse files Browse the repository at this point in the history
  • Loading branch information
andreyyudin committed Dec 7, 2021
2 parents 1ebf541 + 91b07cd commit 701ccdf
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 8 deletions.
59 changes: 53 additions & 6 deletions empiar_depositor/empiar_deposition.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@
"$id": "https://empiar.org/empiar_deposition.schema.json#",
"type": "object",
"definitions": {},
"self": {
"format": "jsonschema",
"version": "1-0-0"
},
"$schema": "http://json-schema.org/schema#",
"properties": {
"title": {
Expand Down Expand Up @@ -118,6 +114,57 @@
"default": [],
"description": "Array of references to IDR"
},
"empiar_references": {
"$id": "/properties/empiar_references",
"type": "array",
"items": {
"$id": "/properties/empiar_references/items",
"type": "object",
"properties": {
"name": {
"$id": "/properties/empiar_references/items/properties/name",
"type": "string",
"pattern": "^EMPIAR-\\d+$",
"title": "The Name Schema ",
"examples": [
"EMPIAR-10002"
]
}
}
},
"default": [],
"description": "Array of references to EMPIAR"
},
"workflows": {
"$id": "/properties/workflows",
"type": "array",
"items": {
"$id": "/properties/workflows/items",
"type": "object",
"properties": {
"url": {
"$id": "/properties/workflows/items/properties/url",
"type": "string",
"pattern": "^https:\/\/.+$",
"title": "The Url Schema ",
"examples": [
"https://doi.org/10.48546/workflowhub.workflow.201.1"
]
},
"type": {
"$id": "properties/workflows/items/properties/type",
"type": "integer",
"title": "The Type Schema ",
"description": "Currently supported value: 1 - WorkflowHub.",
"enum": [
1
]
}
}
},
"default": [],
"description": "Array of workflows"
},
"authors": {
"$id": "/properties/authors",
"type": "array",
Expand Down Expand Up @@ -589,7 +636,7 @@
"type": "array",
"minItems": 1,
"items": {
"$id": "/properties/corresponding_author",
"$id": "/properties/corresponding_authors",
"type": "object",
"properties": {
"author_orcid": {
Expand Down Expand Up @@ -1755,7 +1802,7 @@
"string"
],
"title": "The Details Schema ",
"maxlength": 65535,
"maxLength": 65535,
"default": null,
"examples": [
"Three-dimensional in situ structure of a T4bP machine in its piliated and non-piliated states constructed from its tilt series."
Expand Down
3 changes: 2 additions & 1 deletion empiar_depositor/empiar_depositor.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
under the License.
Version history
1.6b25, 20211015, Andrii Iudin: Added an option to specify workflows, JSON schema updated to the latest draft
1.6b24, 20210729, Andrii Iudin: Switched to top url
1.6b23, 20210113, Andrii Iudin: It is now possible to get entry id and directory as an output on successful deposition
without submitting the entry
Expand Down Expand Up @@ -542,7 +543,7 @@ def main(args=None):
empiar-depositor -r 10 ABC123 -e ~/Downloads/dep_thumb.png 0123456789 -g 01234567-89a-bcde-fghi-jklmnopqrstu ~/Docu\
ments/empiar_deposition_1.json ~/Downloads/micrographs
"""
version = "1.6b24"
version = "1.6b25"

possible_rights_help_text = "Rights can be 1 - Owner, 2 - View only, 3 - View and Edit, 4 - View, Edit and " \
"Submit. There can be only one deposition owner."
Expand Down
6 changes: 6 additions & 0 deletions empiar_depositor/tests/deposition_json/working_example.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@
"name": "EMD-8000"
}
],
"workflows": [
{
"url": "https://doi.org/10.48546/workflowhub.workflow.201.1",
"type": 1
}
],
"authors": [
{
"name": "('Smith', 'JW')",
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

setup(
name='empiar-depositor',
version='1.6b24',
version='1.6b25',
packages=find_packages(),
author="Andrii Iudin",
author_email="andrii@ebi.ac.uk, andrii.iudin@gmail.com",
Expand Down

0 comments on commit 701ccdf

Please sign in to comment.