I have this problem with my Logitech mice too. They work great for two or three years, and then they start registering about one in every 50 clicks or so as double clicks, with the frequency slowly increasing to maybe 1 in 10.
That might just be dust gathering or humidity/temperature weathering. I've fixed most degraded mice by cleaning them, and there's different sprays/lubes you can get that will not only help the hardware but the electrical responsiveness and accuracy.
That and the infinite-scroll wheel bearing fails. I’ve probably gone through 5-10 g502 mice in the past decade. I usually buy them 2-3 at a time when they are on sale.