Mine was doing the same thing. It ended up being the igniter which also acts as a kind of termocouple that controls the voltage to the safety valve. Basically wasn’t allowing enough current to the safety valve for it to open. I also replaced the temp sensor and all’s been good, had it apart so...