It chirps as it is supposed to until it gets gas then stops and gas a green light.
Not sure what "gas detector" you are referring to here but FWIW.... A propane alarm (detector) should be on all the time but when it is powered up for the first time it will go through an internal test procedure and, if successful, will turn on, usually with a green light. This
NOT because it is detecting gas but because it
successfully passed its internal testing. These are usually referred to as "propane alarms" or detectors and should be found mounted low on a wall in the living area. Their purpose is to detect any propane leaks associated with the various appliances and piping and prevent the big BOOM that might occur should you have one. You won't miss it should it go off as it is very loud. In addition, they will usually chirp if the 12V battery system is low.
Some older model detectors are associated with a small gas valve usually located just after the regulator. If the detector fails its boot up test or other otherwise fails, it will not permit gas to flow by not opening the valve. Newer model detectors (97-98+) do not usually have that feature. Replacements for this type of detector can be difficult to find and will sometimes require the bypassing of the valve to get around the problem when installing a new detector.
Some detectors do have an OFF-ON switch but not all.
These alarms usually have a life of 10 years or less and should be replaced when outdated. There is usually a date of manufacture stamped on them, often on the back side. They can be tested by, perhaps by using a "hair spray", sprayed nearby (NOT directly on the unit), (or perhaps by your gassy dog sleeping next to it!!), and it will sound off....
There are also other types of detectors such as a CO (carbon monoxide) detector (often found in motor homes) and that function in a similar manner and smoke detectors (usually on the ceiling), similar to those found at home.