I traveled, pulling a trailer, my 1st trip from Phoenix to Portland, OR, then after a few days, I went on to Colorado Springs, CO. I didn't know what kind of mileage I would get, but found it varied depending on speed and hills. Anyway, after twice filling it to 5.9 gallons, I started carrying a 1 gallon can on the back of the trailer (only filled to .75 for heat expansion). I didn't need to use it on that trip, but did use it on a later trip for my wife's bike when it started sputtering in middle of no-where Nevada. Actually she had a non-venting gas cap issue. What's funny, is a trip we thought we wouldn't have an issue (so didn't bring a can), she ran out of gas (across from a gas station, but she couldn't get to it because of too much California traffic).
So, anyway, I decided that getting the sensor replaced was worth the money. A relatively easy change out, I found with testing that I have 1.2 gallons (average) left when the light comes on (I stopped at the 1st station after the light came on). Living out here, and traveling in, in the wide open west where I have seen signs with "no services for 60+ miles", knowing where the next fillup is is very important (and whether you can get there).
Sorry about your issue, but glad it was a quick resolution. With my wife's bike, it took longer to borrow a can (they wanted over $15 for a two gallon, smallest they had), then to get the gas to the bike. We lost about an hour, all told.

I believe that silly light is part of the bike's safety equipment and should be maintained. On the last trip it came on twice (pulling a heavy trailer over hills and at speed). It was helpful to know that I had at least a gallon left to get to our gas stop.
Thanks for listening,
ken