According to the CDC, you should "NEVER use a gas range for heating".
Never use a gas range or oven for heating. Using a gas range or oven for heating can cause a build up of CO inside your home, cabin, or camper.
Is this valid advice though? Is there any evidence that a gas range not used for cooking is a danger to the household when only burning gas with an open flame? If so, how many hours of use is required for this danger to manifest?
And also the EPA provides similar guidance,
Using a stove hood with a fan vented to the outdoors greatly reduces exposure to pollutants during cooking. Improper adjustment, often indicated by a persistent yellow-tipped flame, causes increased pollutant emissions. Ask your gas company to adjust the burner so that the flame tip is blue. If you purchase a new gas stove or range, consider buying one with pilot less ignition because it does not have a pilot light that burns continuously. Never use a gas stove to heat your home. Always make certain the flue in your gas fireplace is open when the fireplace is in use.