Loose plug in outlet makes circuit work - Weird Issue
I suspect the receptacle is the problem.  Either one of the screws are loose or it is the old stab-in back wired receptacle which were notorious for problems.  The new stab-in's are much improved.  Either way I say replace the receptacle. They need to be changed periodically any way.