Skip to content

Commit 110b02f

Browse files
committed
Fixes NameError in annotation except statement MIT-LCP#253
Fixes the NameError that occurs when incorrect return_label_elements are provided while trying to read an annotation file. Fixes MIT-LCP#253.
1 parent ee0fdb9 commit 110b02f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

wfdb/io/annotation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1717,7 +1717,7 @@ def check_read_inputs(sampfrom, sampto, return_label_elements):
17171717
return_label_elements = [return_label_elements]
17181718

17191719
if set.union(set(ann_label_fields), set(return_label_elements))!=set(ann_label_fields):
1720-
raise ValueError('return_label_elements must be a list containing one or more of the following elements:',label_types)
1720+
raise ValueError('return_label_elements must be a list containing one or more of the following elements:',ann_label_fields)
17211721

17221722
return return_label_elements
17231723

0 commit comments

Comments
 (0)