Is there a more specific exception that can be caught here?