Skip to content
Snippets Groups Projects
Commit d2862f75 authored by Matthew David Pitkin's avatar Matthew David Pitkin
Browse files

Merge branch '109-allow-heterodyne-data-file-merging-to-safely-ignore-empty-files' into 'master'

Resolve "Allow heterodyne data file merging to safely ignore empty files"

Closes #109

See merge request cwinpy/cwinpy!153
parents 4bdaeaab dd637c74
No related merge requests found
......@@ -1136,6 +1136,11 @@ class HeterodynedData(TimeSeriesBase):
else:
datafiles = list(source)
# remove any files that have zero size
datafiles = [df for df in datafiles if Path(df).stat().st_size]
if not datafiles:
raise IOError("No non-empty heterodyned data files were given")
hetdata = read_multi(lambda x: x[0], cls, datafiles[0], *args, **kwargs)
for dfile in datafiles[1:]:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment