Commit 6f259004 authored by Clément Haëck's avatar Clément Haëck
Browse files

Print finder when no files are found

makes it instantaneous to debug the finder / fixes
parent 3eeb90cb
......@@ -56,6 +56,8 @@ def create_data(module, pregex, get_root, ARGS_DIR,
open_mf_kw_def['preprocess'] = finder.get_func_process_filename(
open_mf_kw_def.pop('preprocess_finder'), *pp_args, **pp_kw)
if len(finder.files) == 0:
raise RuntimeError("No files found. \n{:s}".format(str(finder)))
ds = xr.open_mfdataset(finder.get_files(), **open_mf_kw_def)
return ds
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment