During the last thirty years there have been situations where I was called on to manage a workout. Usually the contractor has failed financially and cannot fulfill its remaining obligations. But sometimes the situation is one where the issue is simply cash flow. In any case, the operative principle has always been the same: go forward with a strategy that both completes the contract and minimizes the cost of the workout. Limit waste.
The first workout situation that I managed involved a large sheetmetal subcontract in New York. We found ourselves partway through the project but out of money. We were unable to borrow the money necessary to finance the remaining payrolls but had $1mm worth of work left to complete and, with retainage, just enough money left in the contract to cover those costs. If we walked off the project we had no hope of saving the company.
The Contractor, which held our subcontract, did not like the solution we presented: reimburse our payroll and material costs weekly and we would finish the project. The solution meant the Contractor would have to become our lender until the project was completed; but the alternative - termination and replacement - would have escalated the cost to complete the work significantly. In the end we worked out a deal, completed the contract, reimbursed the Contractor for the interest costs incurred and were able to continue to work to rebuild our company's health.
Yes, I suppose, we breached our contract; however, that was not the end of the story but only the start of the question: how to mitigate the effects of that breach?
Since that first workout I've dealt with similar situations for Sureties and as a Construction Manager with a failing subcontractor.
Call me if you need this kind of experience.