imageio
imageio copied to clipboard
Detect when a file has zero bytes
And raise a sensible exception. Currently, an empty file causes all formats that try to look for a header to fail and this results in an "Could not find a backend to open xx" exception. See #797 for more context.
I will just add that this would also be nice because it can exit early, removing the need to iterate over all backends just to figure out that none of them can read an empty file.