MaimonLab / SiffPy

Code for fast analysis of ScanImage .tiffs and .siffs
GNU General Public License v3.0
4 stars 1 forks source link

Throw interpetable exception if file is not correctly parsed , i.e. it's not a tiff or siff file #9

Closed MaximilianHoffmann closed 4 months ago

MaximilianHoffmann commented 4 months ago

Maybe throw a value error with a more interpretable error message when parsing already fails for the TIFF header.

StephenThornquist commented 4 months ago

This has now been changed. If you build corrosiff-python from the source repository (after installing cargo) instead of PiPy, or wait for the next release, you will get the error: OSError: File format error -- invalid or incompletely-transferred siff file if you try to open an invalid file