What happens to the settlement?

If 2 spouses sign a separation agreement that states that a jointly owned house is to be sold and the proceeds are split, with a greater portion going to the supported spouse (in exchange for leaving the supporting spouses 401K alone).

The 2 people then divorce. 2 years pass.

The 2 people pay the mortgage 50/50 while the house is for sale. Housing market goes in the tank.

Then one spouse (the supporting spouse) losses their job. They can no longer pay their half of the mortgage. The other spouse cannot pickup the full mortgage. The house is foreclosed and lost.

What happens to the portion of the award that was to be paid to the supported spouse? Separation agreement clearly states they will be paid this amount from the proceeds of the sale.

If the separation agreement did not account for that uncertainty there is not much that can be done. If no sale resulted due to circumstances outside of your control, the proceeds are zero.