Book with a marriage pact

okay, I've already requested this a few weeks ago on a mega thread, but I'm making a separate post so that it has a greater reach since that comment didn't get any responses (I'm sorry if this is not allowed!)

I want to read a book where the FMC and the MMC promise to marry each other if they're still single by xyz age, and then grow apart, and then years later when they're xyz age, one of them shocks the other by showing up and demanding to get married.

I've only read this trope in contemporary. I feel like it'd be *chef's kiss* in a historical setting.

I think I've read hr books where they had a contract requiring them to get married, but it's usually their parents who do that.

It'd also be preferable if they grew apart because of a falling out.

Thank you!