fix how connect_all deals with failures