2004 PT Cruiser Camshaft and or Crankshaft Sensor

I had both of the above sensors replace within a month of each other back in March. Ever since then one keeps “resetting”. When I accelerate, it chugs, the engine light comes on. When the mechanic looked at it he said it wasn’t doing it. He said he couldn’t do anything unless the sensor was acting up. It seems when I turn the car off and back on it resets and it runs fine. I am so frustrated! I know he can hook the car up and see the error message, but if the car is running what can be done?