The essence of modern economics can be summed up in two words: borrowing money. One generation spends, and the next spends a lifetime paying it back.
I think your point is towards what underdeveloped countries do, the previous generation tried to borrow money under the pretext of improving human resources, but behind all that they also work like a saw, every swing will produce money into their pockets. While the next generation is responsible for paying it back, as far as I know, the new government also has the same ideology, borrowing money under the pretext of wanting to solve more complex problems. This problem is too complicated, it might always revolve around the same line or be like a relay that has no finish line.
The IMF or developed countries that have a lot of money will always reach out to lend money to underdeveloped countries, they also have goals, Some countries have to lose their assets because they fail to pay their debts, such as Sri Lanka having to lose its ports and airports because it failed to pay its debts to China.
I think it has become a trend where governments in almost all countries except developed countries consider borrowing as their earning money and they spend that money as if it were their own money. But because of this borrowing, countries are losing their wealth and are also becoming financially weak. If governments want to increase their corruption instead of suppressing it, I don't think there will be any good solution.
Moreover, the developed countries are just sitting around lending money. They will lend money at high interest rates with various conditions and if a country fails to pay the borrowed money, they will definitely have to give value for it. Which is what Sri Lanka did. However, the country's skilled and honest leadership has been able to pull them out of that dire situation.