More error checking and retries for hitting the twitter API