Hyundai Repair: Rough Idle then stall, head gasket, hyundai accent


Question
1. The head gasket was replaced because there was a small amount of Carbon Monoxide coming out of the radiator when we did the block test.
2 the mechanic did check the flatness of the head once the head was removed and it was ok.
3. once the head was put back on the block and a everything else was put back together, I had to run the car for about an hour to get all of the air out of the cooling system.
4. the check engine light is not on.
6. the engine is not misfiring, when the car is not at idle, it has really good power. so it runs well at a higher rpm.
7. the mechanic said that he checked the timing once the head was put back on. I would assume that he checked both the belt and the chain.
-------------------------------------------
The text above is a follow-up to ...

-----Question-----
I have a 2001 Hyundai Accent GL w/ 1.6 I4 engine. My car has 150,000 miles on it. I am having a problem with the car staying running.  It seems to run ok when you first start it and it is cold. However, when the engine gets up to N.O.T. The car idles really rough until it stalls.  It stalls mostly after the rpm changes (i.e. stop light) I recently replaced the head gasket, so the timing is correct. My mechanic gave me some ideas including cleaning out the throttle body with carb cleaner and a toothbrush, and spraying carb. cleaner around the intake and vaccum hoses to see if there is a vaccum leak. He said the engine idle speed would change if the carb. cleaner is sucked into the intake. He also said it could be due to cavitation since the cooling system was drained  when the head gasket was changed. I have fixed the cavitation problem, and cleaned out the throttle body, and checked for vaccum leaks however it still stalls. I'm out of ideas, and I'm stumped.
-----Answer-----
Hi, Chris.  If you can, please let me know the following:

1.  Why was the head gasket replaced?
2.  Did you check the flatness of the head and block when the head was off?
3.  Do you or did you have a problem with air in the cooling system after the head gasket was replaced?
4.  Is the check engine lamp on?
5.  Is the engine misfiring?
6.  Did you recheck the camshaft timing (both the chain and belt) to verify that they were indeed both correct?

Answer
The fact that the check engine lamp is not coming on suggests that this problem is probably not related to the fuel management system.  Before getting involved in any serious work, I'd recommend pulling the valve cover and upper timing cover and rechecking the timing belt and chain.  If the mechanic says he checked the timing, he may be referring to ignition timing.  Hard to tell.

Out of curiosity, why were you checking for carbon monoxide in the radiator?