Be very careful with the "mistake of fact" approach. The mere nondeductibility of a contribution is NOT a mistake of fact. Take a look at Rev. Proc. 90-49, as well as IRS Notice 89-52, and PLR 9144041. I think you'll find that your situation won't allow use of this.