Factionalism effectively quashed the Corbynites but has undermined Keir Starmer’s leadership of party and country