I have a 9 year old Bradford White gas water heater, model MI403S6FBN4. The pilot light went out today, and when I went to re-light it, it stays lit while the pilot button is held down, and it stays lit after I turn the switch to the ON position. However, it goes out immediately when I replace the outer door (which covers the viewing window). The metal of the door seems to be tripping what is, according to the online manual, the "Nat. Gas Resettable Thermal Switch". I've read a bit online and this seems to be a safety device, so I've turned the gas off to the water heater and left it unlit, but what causes that switch to trip, and what needs to be done to fix the issue? Or does the switch just need to be replaced?
My furnace is also gas and also has a safety device to snuff the pilot light in case it detects gas outside the combustion chamber, but it hasn't tripped. I called the gas company, they came out and didn't detect any gas in the air (I thought I smelled it but it was actually some urethane smell or something), so it wasn't the presence of gas that was causing it.