We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0c175b4 + e2fd822 commit 620a2a8Copy full SHA for 620a2a8
neo/core/baseneo.py
@@ -45,7 +45,9 @@ def _check_annotations(value):
45
if not issubclass(value.dtype.type, ALLOWED_ANNOTATION_TYPES):
46
raise ValueError(f"Invalid annotation. NumPy arrays with dtype {value.dtype.type}" f"are not allowed")
47
elif isinstance(value, dict):
48
- for element in value.values():
+ for key, element in value.items():
49
+ if not isinstance(key, str):
50
+ raise TypeError(f"Annotations keys must be strings not of type {type(key)}")
51
_check_annotations(element)
52
elif isinstance(value, (list, tuple)):
53
for element in value:
0 commit comments