...and a real life application of the doctrine of estoppel.
When an attorney misses the deadline to respond to a motion and judgment is taken against his client, C.C.P. section 473 provides a means for setting aside the judgment.
When an attorney is trying to negotiate a resolution to the dispute to avoid litigation and trusts the other side that says “We’re almost there…” and the statute of limitation runs, the attorney should invoke the doctrine of estoppel and file a motion for leave to file the complaint based on the holding in Carruth v. Fritch (1950) 36 Cal.2d 426, that one cannot justly or equitably cause his adversary to subject his claim to the bar of the statute of limitations, and then be permitted to plead the very delay caused by his course of conduct as a defense to the action when brought. The statute of limitations may never be used to assure the success of a fraud.
When the court simply gets it wrong, the attorney should consider a motion for reconsideration or a renewal of the original motion, or perhaps a writ (of review for example).