One approach to control optimism is to have an unassailable understanding of the facts.
When there is optimism in the air, then asking and answering fact based questions clears the way to understanding if that optimism is founded in fact.
There is no better place than on a project to seek a fact based discussion. This starts with the planned description of physical percent complete.
One this day we plan to have 40% of all the database interface code complete, integrated, tested, and checked into the source cde control system. By tested we mean tested against the pre-planned Unit and Integrated test procedures. By checked in we mean the code is complete and ready to be put to use by others.
Come that day, we can check to see if what we planned to do, we actually did.
If yes, we get 100% credit for spending our planned budget. If no, then we can't be on schedule, on budget, or compliant with the technical performance plan.
Only tangible evidence of physical percent complete is a credible indicator of progress to plan.