Adding github api error handling.