@@ -154,7 +154,10 @@ def configure_checks(
154154@click .argument ("path" )
155155@click .option ("--modules" , help = "Modules to import prior to reading the file(s)." )
156156@click .option (
157- "--report-file-path" , default = None , help = "Save path for the report file." , type = click .Path (writable = True ),
157+ "--report-file-path" ,
158+ default = None ,
159+ help = "Save path for the report file." ,
160+ type = click .Path (writable = True ),
158161)
159162@click .option ("--overwrite" , help = "Overwrite an existing report file at the location." , is_flag = True )
160163@click .option ("--levels" , help = "Comma-separated names of InspectorMessage attributes to organize by." )
@@ -459,7 +462,9 @@ def inspect_nwb(
459462 filterwarnings (action = "ignore" , message = "No cached namespaces found in .*" )
460463 filterwarnings (action = "ignore" , message = "Ignoring cached namespace .*" )
461464
462- def _collect_all_messages (nwbfile_path : FilePathType , checks : list , driver : Optional [str ] = None , skip_validate : bool = False ):
465+ def _collect_all_messages (
466+ nwbfile_path : FilePathType , checks : list , driver : Optional [str ] = None , skip_validate : bool = False
467+ ):
463468 with pynwb .NWBHDF5IO (path = nwbfile_path , mode = "r" , load_namespaces = True , driver = driver ) as io :
464469 if not skip_validate :
465470 validation_errors = pynwb .validate (io = io )
@@ -488,16 +493,20 @@ def _collect_all_messages(nwbfile_path: FilePathType, checks: list, driver: Opti
488493 )
489494
490495 if driver != "ros3" :
491- yield _collect_all_messages (nwbfile_path = nwbfile_path , checks = checks , driver = driver , skip_validate = skip_validate )
496+ yield _collect_all_messages (
497+ nwbfile_path = nwbfile_path , checks = checks , driver = driver , skip_validate = skip_validate
498+ )
492499 else :
493500 retries = 0
494501
495502 while retries < max_retries :
496503 try :
497504 retries += 1
498- yield _collect_all_messages (nwbfile_path = nwbfile_path , checks = checks , driver = driver , skip_validate = skip_validate )
505+ yield _collect_all_messages (
506+ nwbfile_path = nwbfile_path , checks = checks , driver = driver , skip_validate = skip_validate
507+ )
499508 except OSError : # Cannot curl request
500- sleep (0.1 * 2 ** retries )
509+ sleep (0.1 * 2 ** retries )
501510
502511
503512def run_checks (nwbfile : pynwb .NWBFile , checks : list ):
0 commit comments