Question: I've been told that I am to be a team lead of an upcoming project. I've not ever been team lead before but the responsibilities are what you would typically expect, with revolving door of 3 to 4 other developers through the 8 or 9 months it takes to complete the project.

My problem is this: one of the developers who will no doubt be working on this project will be a problem. He has more experience than me, has called me an idiot several times in the past, and has told me that he has taken this job because he is a natural leader. He has expected to be promoted to a leadership position with every new project (which has not happened to date), and even once told me that I was to report to him, even though the actual team lead was under no such illusion. Moreover, I've both observed and heard from others that he is extremely unprofessional (watches non-work videos at client sites - with no head phones, dresses unprofessionally, comes to work late, makes inappropriate jokes, etc.) He took or attempted to take credit for my work or insights multiple times while I worked with him as a peer. My current team lead told me that she threw out 1/2 of this guy's code once he left her project because the quality was no good. I could go on.

My fear is that this guy will actively work against me, because he will resent having to report to someone that he considers an inferior, especially since I have been given this opportunity before him. I've successfully dealt with this type of personality as a peer or even reporting to managers like this in the past. I've not dealt with, or ever thought about, having to deal with this type of character who is reporting to me. 

My question is: what kind of strategies can I use to effectively and professionally deal with this? Especially now, before it has become a problem, is there any way to cut it off before it gets out of hand etc. If anyone has a similar experience how did they deal with it?

Answer: 
You are in a tough spot, because if this guy wasn't fired yet then he either has political importance or you work for an organization that will never fire people for performance.

Pray it is the latter, that is much easier to deal with. Politically important troublemakers like that can ruin you despite ALL of your best efforts to be professional, cover your *\**, and document EVERYTHING. I have seen it happen. The paper trail means nothing when politics are involved.

**Be Professional -** Don't try to be friends with anybody on the team. Act as if you are on a mission the entire time and do not show favoritism.

**Protect yourself/Document EVERYTHING -** Don't make silly mistakes, you are being watched. The sharks are attracted to blood in the water. Also make sure that you fully document all decisions, email trails, discussions and team consensus. When you get dinged on something you will want to pull up that email from 6 months ago.
Just keep your humor. If you can't get rid of him, the worst thing you can do is let him bother you. He's not a big deal. He wants you to be nervous. He wants to be "that guy". Let him be "that guy". Just keep your good humor and always look on the bright side.

Handle him. Don't let him handle you.