From 4a0ecc1c15ea779b60952701cdb16a29b43651c1 Mon Sep 17 00:00:00 2001 From: Paul van Schayck Date: Thu, 14 Nov 2024 14:18:51 +0100 Subject: [PATCH] Default value for values should be [] --- src/covjson_pydantic/ndarray.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/covjson_pydantic/ndarray.py b/src/covjson_pydantic/ndarray.py index 6906335..25b9057 100644 --- a/src/covjson_pydantic/ndarray.py +++ b/src/covjson_pydantic/ndarray.py @@ -26,7 +26,7 @@ class NdArray(CovJsonBaseModel, Generic[NdArrayTypeT], extra="allow"): dataType: DataType # noqa: N815 axisNames: Optional[List[str]] = None # noqa: N815 shape: Optional[List[int]] = None - values: List[Optional[NdArrayTypeT]] = None + values: List[Optional[NdArrayTypeT]] = [] @model_validator(mode="after") def check_data_type(self):