Might be corrosion in the bulbs socket.
It’s really strange, does the same thing on high and low beam. I will check that connection to be sure.Most likely a faulty connection at the LH handlebar switch assy
I just figured it out. When the lights cut off I squeezed the circuit breaker bag and then they came back on. Looks like I’ll be replacing the breaker.