I have been fighting this problem for a month or so. I swapped my fried tib motor with a newer Sonota motor and now I cannot get the check engine light to turn off.
First, I had a p0031 code for the O2 sensor bank1. The car ran very good though. It turns out that I had the signal wire connected wrong for the O2 sensor. Once this was fixed, the car runs very bad now.
With the o2 sensor connected correctly, I have very poor acceleration until around 3k rpms where the car will pick up nicely. It idles roughly around 500 rpms. There are 6 codes now: p1166, p300, p301, p303, p305, p174.
If I disconnect the o2 sensor, the car will run fine and of course throw the p0031 code. I have cleaned the MAF sensor and replaced the PCV valve. If I spray starting fluid around the air intake and manifold, there is no idle acceleration.