Since it is an intermittent problem it could be nothing more than an intermittent condensate/contaminant in the gas supply coming from the gas company. Sometimes oil or other chemicals can get into the supply at the pumping station - sometimes just mixing in too much odorant can cause the problem.
The next time you notice it - check with a neighbor that has a gas stove and see if they are getting the same thing. If so, it pretty much points to being dirty gas. If it is only in your stove - then you might have some other problem.
FWIW: I noticed it more frequently when I lived in Golden than I do down here - but it does still happen here from time to time.
"It ain't what you don't know that gets you in trouble. It's what you know for sure that just ain't so." - Mark Twain