I had the same problem last week. I jacked the car up and took the external wastegate off to replace the pipework with nice blue ones. The car was running fine the day before. Put it all back together, went to crank it over and it wouldnt start, it kept trying to but as it started to fire it would die.
I got a strong smell of fuel and thought that id flooded it, so i took all the plugs out and left it for 3 days. When i took the plugs out they were very black and dripping with fuel. I had been over fueling for a while.
I bought some new plugs and put them in expecting to be out cruising within half an hour. Tried starting it and exactly the same again.
I checked the 02 sensor connections and my maf connections and they were fine, checked all fuses, all fine and was begining to pull my hair out.
I then noticed that the lower big clip that does the water temperature i think had a very old brittle wire going to it, as i touched it it broke off, so i crimped some new connectors onto the two wires and it started first time.
A long write up but it sounds very very similar to yours, maybe you should fit that new connector anyway incase there is a problem inside it.
Hope this helps.
Oh and my car now idles sweeter than ive ever heard it