I agree with all of this but I would add that many of the best people in the party would have been associated with the previous leadership and hence their failure and so are not really available to be selected as the new leader or are handicapped by their association. I think we saw this in 2010 when the wrong Miliband brother was selected and I think we saw that in 2015 when anybody associated with Ed Miliband was hamstrung by his failure.
Possibly true but you then get into the 'clean slate' vs 'no experience' argument - so someone who is completely untainted by being a minister in the dying days of a failing government may be criticised for not having any actual government experience if they become leader of the opposition. But of course when parties are out of power for an awfully long time you end up burning through all the ex-ministers as potential leaders and often end up with a leader who wins power back having never been a minister themselves.
So from 1979 Labour burned through ex ministers Foot and Smith (Kinnock was never a minister) before ending up with a winner, Blair who had no ministerial experience.
Likewise the Tories - Hague and Howard - both former ministers (IDS was never a minister) before ending up with a winner, Cameron who had no ministerial experience.
Looks like we will have a similar situation now - Miliband was a minister, Corbyn never was and Starmer also has no ministerial experience.
Just a little note on Corbyn - by 2015 he'd been an MP since 1983 (so through periods where Labour was in opposition, then in power, then in opposition) - in all that time no-one thought he had the abilities to be offered any ministerial or shadow ministerial position (even the most junior) - nor even chair of a select committee. Speaks volumes about how his colleagues saw his competence!