We were confronted years ago with a thermostat that we thought had a mind of its own. In the summer, as the outdoor temperature increased, the thermostat would show an ever increasing indoor temperature, but our separate HVAC thermometer always showed much lower indoor temperatures. The home owner said that sometimes there was a 10°F difference between the thermostat's temperature reading and another thermometer's reading. The same problem happened in the winter, but not nearly as much.
We removed that thermostat and installed a new one, only to have the same problem with the new thermostat. So we placed a temperature probe inside the thermostat, to measure the air temperature at the thermostat's sensor. We discovered that the temperature inside the thermostat was actually what the thermostat said. How was this happening - where was the heat coming from? We figured it had to be coming out of the wall, but why would the inside of the wall be so hot?
Sure enough, there was hot air coming out of the wall into the thermostat. We eventually found that it was getting into the wall from the attic via holes that were drilled for the home's wiring. This happened because the pressure in the attic was higher than the pressure in the rest of the house. We're not sure why the attic pressure was so high, but it caused the hot air from the attic to be forced down the wall, and into the hole where the thermostat wires ran into the back of the thermostat. The hotter it got in the attic, the higher the thermostat would say the indoor temperature was, and the longer the air conditioner would run. To correct the problem we simply blocked the hole where the wires went through the drywall.
From a few other cases like this, we've seen that homes that have fiberglass batt insulation are more likely to have this problem then homes that have blown in insulation. It doesn't mean that every home with fiberglass batt insulation will have this problem, it just means it's more likely.