Skip to content

Commit e1c898a

Browse files
authored
Merge pull request #1445 from zm711/spikeglx
SpikeglxRawIO: raise error if no `.meta`-`.bin` combos of files detected
2 parents e0e81a6 + 00690a5 commit e1c898a

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

neo/rawio/spikeglxrawio.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,9 @@ def scan_files(dirname):
298298
info["bin_file"] = str(bin_filename)
299299
info_list.append(info)
300300

301+
if len(info_list) == 0:
302+
raise FileNotFoundError(f"No appropriate combination of .meta and .bin files were detected in {dirname}")
303+
301304
# the segment index will depend on both 'gate_num' and 'trigger_num'
302305
# so we order by 'gate_num' then 'trigger_num'
303306
# None is before any int

0 commit comments

Comments
 (0)