Skip to content

Commit 6e9616d

Browse files
committed
Add error message hint for special case issue
1 parent e73a328 commit 6e9616d

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/mdio/builder/dataset_builder.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -232,6 +232,15 @@ def add_variable( # noqa: PLR0913
232232
raise ValueError(msg)
233233
if dimensions is None or not dimensions:
234234
msg = "'dimensions' must be a non-empty list"
235+
if name == "trace_mask": # coverage: exclude
236+
msg += (
237+
"Error occurred while adding special case variable `trace_mask`."
238+
"This is likely an issue with how a custom template has been defined."
239+
"Please check the documentation https://github.com/TGSAI/mdio-python/issues/718 "
240+
"for more information."
241+
# TODO(Anybody): Update the link to point to the appropriate documentation when it is available.
242+
# https://github.com/TGSAI/mdio-python/issues/718
243+
)
235244
raise ValueError(msg)
236245

237246
# Validate that the variable is not already defined

0 commit comments

Comments
 (0)