Since it was not working and then working and not working I think there must be something loose somewhere.
Ugh! I had that happen. The whole driver's side of the coach's power went out, including the microwave and A/C. It took me awhile to find it. A wire had worked loose from the wire nut. Luckily it was in a bundled connection behind the microwave.
I used an ohms meter to eliminate sections of the wiring: Georgie Boy did not make straight (or logical) runs. Then found it by wiggling all the most likely suspects with the non-working lights turned on. I would have missed it if the lights hadn't been in the on position. It didn't feel, or appear, loose. It was still inside the nut. That one wire had just worked its way down to a point where it no longer had contact with the live power.
Oh, yeah, they always recommend turning OFF the power when you work on electricity. I'd been over this bunch of connections twice with the power off. So ah, if you end up having to work with live power to find it, as a last ditch effort only, like I did, be EXTREMELY careful. Do not touch any metal to the live wires! Do not touch any exposed wires with the power on! Once I found out which one had the problem I turned THE POWER OFF before fixing it. Really important!!!