Except that that is not really how it works in Canada. We have a minority government, meaning that in theory the election could come at any time, meaning that he as the leader of the Liberal Party would be running again. If this Liberal-NDP deal magically holds out till 2025 we might see him stepping down about six months before the election. So maybe we will see the deal magically disappear and an election call in early 2024?
Either way, it is important to remember that the sitting Prime Minister has run in every Canadian election since confederation.