From c89bdfa87f906d3677e34f0fc9d6cc0392f02300 Mon Sep 17 00:00:00 2001 From: David Hammer <dhammer@mailbox.org> Date: Wed, 20 Dec 2023 15:25:56 +0100 Subject: [PATCH] Revert "Unrelated: remove default values in output schemata for 2.19.x" This reverts commit 4e0be11e29e1218915d5b5d847e489bed2656121. --- src/calng/schemas.py | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/calng/schemas.py b/src/calng/schemas.py index 0fc434ec..bbe2f9e7 100644 --- a/src/calng/schemas.py +++ b/src/calng/schemas.py @@ -80,7 +80,7 @@ def xtdf_output_schema(use_shmem_handle=True): VECTOR_STRING_ELEMENT(res) .key("calngShmemPaths") .assignmentOptional() - .noDefaultValue() + .defaultValue([]) .commit(), NODE_ELEMENT(res) @@ -90,7 +90,7 @@ def xtdf_output_schema(use_shmem_handle=True): STRING_ELEMENT(res) .key("metadata.source") .assignmentOptional() - .noDefaultValue() + .defaultValue("") .commit(), NODE_ELEMENT(res) @@ -100,7 +100,7 @@ def xtdf_output_schema(use_shmem_handle=True): INT32_ELEMENT(res) .key("metadata.timestamp.tid") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), NODE_ELEMENT(res) @@ -110,37 +110,37 @@ def xtdf_output_schema(use_shmem_handle=True): INT32_ELEMENT(res) .key("header.minorTrainFormatVersion") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), INT32_ELEMENT(res) .key("header.majorTrainFormatVersion") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), INT32_ELEMENT(res) .key("header.trainId") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), INT64_ELEMENT(res) .key("header.linkId") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), INT64_ELEMENT(res) .key("header.dataId") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), INT64_ELEMENT(res) .key("header.pulseCount") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), NDARRAY_ELEMENT(res) @@ -158,7 +158,7 @@ def xtdf_output_schema(use_shmem_handle=True): INT32_ELEMENT(res) .key("detector.trainId") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), NDARRAY_ELEMENT(res) @@ -180,13 +180,13 @@ def xtdf_output_schema(use_shmem_handle=True): INT32_ELEMENT(res) .key("trailer.status") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), INT32_ELEMENT(res) .key("trailer.trainId") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), ) @@ -217,7 +217,7 @@ def jf_output_schema(use_shmem_handle=True): INT32_ELEMENT(res) .key("data.trainId") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), NDARRAY_ELEMENT(res) @@ -239,7 +239,7 @@ def jf_output_schema(use_shmem_handle=True): VECTOR_STRING_ELEMENT(res) .key("calngShmemPaths") .assignmentOptional() - .noDefaultValue() + .defaultValue([]) .commit(), ) if use_shmem_handle: @@ -269,7 +269,7 @@ def pnccd_output_schema(use_shmem_handle=True): UINT64_ELEMENT(res) .key("data.trainId") .assignmentOptional() - .noDefaultValue() + .defaultValue(0) .commit(), ) if use_shmem_handle: -- GitLab