This type of trouble has been reported several ways over the years.
It’s almost always traced back to bad wiring, bad socket, defective bulb.....almost anything related to a bad ground in the circuit.
Check the operation of ALL YOUR LIGHTS.....WITH AND WITHOUT FULL LIGHTING SYTEM.
Let us know what you find.
__________________
Ken and Terry
2018 Sunseeker 2430S-CD, nicely modified and carried by a 2017 Ford E450 Sport
Former Georgetown 330TS owner for 10 years with more mods than I can count, pushed by our 2017 GMC Terrain