[src] Adding in some helpful error handling