My understanding is that when a liquified gas expands back into a gas it cools down because energy is need for the expansion and this energy is supplied by the available heat in the nearby area, thereby causing cooling.
If this is the the case then I would assume that a tightly enclosed container holding liquid helium will not be cold but rather at the ambient temperature. The helium may be exerting a lot of pressure on the wall of the container but so long as no helium escapes the container will not be cold.
If my assumptions so far are correct how does immersing something like the infrared detectors used on telescopes in liquid helium cause them to be cooled unless there is a deliberate venting of the helium?
Am I missing something or are my assumptions correct?