Unplugging the detector in the quantum double slit experiment I'm thinking about the quantum double slit experiment. Specifically the part where if you had a detector pointing at one of the slits, this would collapse the wave function and the interference pattern would disappear.
I then watched a video about it that said something like "if you go and quietly pull the plug on your detector (trying to "trick" the experiment) then the interference pattern would return.
I understand this as a way to educate and explain the concept, but I thought that I had heard that the things that actually collapse the wavefunction are ambient photons interfering with the experiment - i.e. a stray photon would bounce off of the electron and scatter into the detector, giving us the information about what slit the electron went through.
So in practice, if you just unplugged your detector in your well-lit laboratory, I'm guessing that this wouldn't change the outcome of the experiment at all - there would already be no interference pattern because of the ambient photons.
Similarly, if you had a completely dark room devoid of photons, whether your detector was plugged in or not would make no difference, as if would not be able to "see" where the electron was and so there would be no interference pattern in either case (plugged in or not).
Is this the right way to think about things?
 A: Yes, the interference pattern goes away when the "which-way" information of the electron leaks out into the environment. If a stray photon bounces off the electron, in a way so that one can tell in principle which way the electron went from how the photon bounced off, then the interference pattern goes away, whether or not you directly detect the photon.
When these kinds of Youtube videos talk about detectors, they don't mean passive detectors that just look for scattered photons, because those wouldn't make any difference. They have in mind some kind of active detector, such as one that shines a strong pulse of light at the slits. It is definitely misleading to describe using such a detector as "looking" at the slits, since passively looking doesn't do anything.
Also, while it does help to have a dark lab, you don't need to be obsessive about blocking out ambient light. Experiments like these tend to be very small, and the electron-photon scattering cross section is small too. Of course, it does become extremely important in "macroscopic" superposition experiments when you try passing much larger things through the slits.
For example, you can do double slit experiments with fullerene molecules, which can be used to demonstrate "thermal decoherence". That is, if the molecule is excited, then the which-way information can leak out when the molecule itself emits a photon, even in a completely dark room. As you can see in the link, there's a direct relationship between suppressed the interference pattern is, and how hot the molecule was before it entered the slits. That relationship of course doesn't require the emitted photons to be detected by an apparatus.
A: To enlarge ever so slightly (and perhaps trivially) upon Knzhou's excellent answer, the key issue is that the "which-slit" detector must assert an active measurement upon the photons passing through the slit i.e., it detects them by interacting with them in some manner, and that interaction alters the photons' states. Imagine that this measurement involves, for example, applying an electric field in some manner to the slit. The exact details of the measurement need not concern us here except that when you pull the plug on the detector, that field disappears and it suddenly is no longer perturbing the photons passing through the slit.
In this case, shutting down the detection mechanism leaves the photons unaltered and the which-way difference in the states of the photons going through the two slits disappears, and the interference pattern returns.
Then you realize that on the level of individual photons, there is no such thing as a passive detector- any detector that can theoretically sense the passage of one photon has to interact with it, and "taint" it in just such a way as to destroy the interference pattern.
I'll delete this addendum if knzhou deems it trivial.
