I'm a specialist at my company. Almost a year ago we hired someone to help me out (before, I was the only programmer in my department). He proved to be below average, but has been helpful in taking simple tasks off my plate during a big project. The plan was to train him up over the course of the project to be able to handle more advanced material. This training plan was clearly communicated to him.
In the course of training I've realized he is absolutely incompetent. I was very patient with him, but his work is not up to standard. I feel unable to trust him to write even a simple "fizzbuzz"-style program unaided, even if I had solved similar problems with him the previous day and gave him excess time and hints. I am confident in this judgement, as I'm his direct supervisor. Management trusts me completely, but would like to keep him until the end of said project.
I've tried giving him work in other areas, including in other departments, but he's been unsuccessful there too. I've discussed his low performance with him, but he is very eager and enthusiastic. He seems to overestimate his own ability even when problems are demonstrated to him.
So, I made my decision: once the project is finished, he will be laid off. I expect this to take another few months. My decision is final, and I'm certain that there is not another place at the company for him. I have two choices:
Tell him now. This might significantly reduce his dedication to the current project, and he might leave before it is finished, which would be a setback.
Wait until 2 weeks before firing him; this is the minimum notice period required by law. For the sake of the company and the project this would be the most optimal solution, but it would weigh on my conscience to do so. He should have at least some time to search for a new job, and in our area, it's hard to find one at short notice.
How do I weigh these options to make the best choice?