diff --git a/emmet-core/emmet/core/tasks.py b/emmet-core/emmet/core/tasks.py index b7f08a8b5d..35d6ac5a68 100644 --- a/emmet-core/emmet/core/tasks.py +++ b/emmet-core/emmet/core/tasks.py @@ -1,6 +1,6 @@ from datetime import datetime from enum import Enum -from typing import List, Dict +from typing import List, Dict, Union from emmet.core.vasp.task_valid import TaskState @@ -144,7 +144,7 @@ class TaskDoc(BaseModel): Calculation-level details about VASP calculations that power Materials Project. """ - tags: List[str] = Field( + tags: Union[List[str], None] = Field( [], title="tag", description="Metadata tagged to a given task." ) diff --git a/emmet-core/emmet/core/vasp/task_valid.py b/emmet-core/emmet/core/vasp/task_valid.py index b875f9bf78..ae8f66aa2e 100644 --- a/emmet-core/emmet/core/vasp/task_valid.py +++ b/emmet-core/emmet/core/vasp/task_valid.py @@ -34,7 +34,9 @@ class BaseTaskDocument(EmmetBaseModel): description="Timestamp for this task document was last updateed", ) - tags: List[str] = Field([], description="Metadata tags for this task document") + tags: Union[List[str], None] = Field( + [], description="Metadata tags for this task document" + ) warnings: List[str] = Field( None, description="Any warnings related to this property"