The principle is that yellow phosphorus is combined with other flammable substances. This special substance is not volatile in the air and may be the ever-burning lamp of the ancient tomb. As soon as the tomb door is closed, the air in the tomb will slowly run out, and even the ever-burning lamp will go out. But when hundreds or thousands of years later, as long as someone enters the tomb, it will bring fresh air and ignite the ever-burning lamp that will spontaneously ignite under normal circumstances. This is also the mystery that the ever-burning lamp is still on when people enter the ancient tomb for thousands of years.
In some cases, lamp oil will spontaneously ignite and volatilize, producing some combustible gases. In the absence of oxygen, the tomb is very well sealed, and these gases have always existed in the tomb. Once the tomb door is opened, the gas will ignite instantly, which will form the phenomenon that people often say that it will last for thousands of years.
However, white phosphorus is toxic, and it is very dangerous to use ever-burning lamps at home. Therefore, there is no such thing as an ever-burning lamp. In the closed environment of ancient tombs, oxygen is needed for any combustion. When the oxygen is used up, the light will naturally go out. Of course, the ever-burning lamp also has the function of pumping out oxygen to keep the funerary objects from being oxidized.