make the agent retry properly