(Should be done in another PR) We should have a generic superclass for errors coming from requests (like we do with git) (#739)