[writer] disk full response
When the disk is full, the HDF5 file gets corrupted while it should just stop writing.
I could have to writer preform this check:
statvfs = os.statvfs(filename)
if (statvfs.f_frsize * statvfs.f_bavail / 1024**2) < 100:
raise RuntimeError("Free disk space below 100MB")
Then the scan will stop and the HDF5 file is not corrupt. The next scan will not even start.
The question: how often do we check? Every NEW_DATA event is the safest but this happens too often I suppose. Every x seconds like the HDF5 flushing? Depending on the data rate we might be too late with the check though.
Any comments @sole @andy.gotz @matias.guijarro ?