There are times, when we make the same mistake again and again. We wonder, why we falter despite our resolve never to get into that mess again.
Every mistakes we do spring from a web of dysfunctional habits. For example- not claiming the expenses of shipping your household stuff even after months of relocation because you lost the cargo invoice. Why did you lose the cargo invoice? It is because you are disorganized. Why are you disorganized, even though you have read a lot of books about organizing things? It is because you procrastinate. Why do you procrastinate?---.
Hence if you want to prevent a mistake, you may need to take action in multiple areas, not just resolve never to do that mistake again.
A complete post critique of what went wrong and which habits contributed to the mistake will be the first thing to do.
Based on the post critique, you need to develop an action plan to prevent the mistake once and for all. Please remember, you may need to look beyond yourself too, because the dysfunctional habits that contributed to the mistake may not lie with you alone.
I think the best person to start with is yourself.
In my experience, I have always hit "pay dirt" when I started with myself.