Our fireplace turns on fine, runs for a while and then all of a sudden goes out, then sometimes comes back on. We usually turn it off when it happens. We have had a fireplace company out they replaced the thermocouple and it still continues. We have also had the fireplace cleaned, venting was resealed and it still continues. Our local fireplace company is stumped and we are too! We really enjoy using this and now I have turned it off as we don't know what's going on and don't feel safe using it till we know and fix it.
You may have a condition where the control wiring for the fireplace is run through the same drilled holes in the floor joist, etc. as the standard house wiring are run through. When a light is turned on or off or the microwave is started, this current drawn so close to the control wires can induce enough voltage in these wires to disrupt and or start the fireplace independent of thermostat control. Fully separate all control wiring from other wiring by at least 2-feet (perpendicular runs are OK). I have seen this fix this problem.