Features/better error handling