Early in the codebase, we were sloppy about error types. Many errors were just defaulted to using IO errors, even if they had nothing to do with IO failures.
#3159 is an example of this, but there are many more obvious ones throughout the codebase.
We need to review these instances and map them to a more appropriate error type. Pay special attention to ones that need to be changed to Error::InvalidInput.