I'm still using my original Magicshine. I know they were hard to connect & disconnect. to counter that, I roughed up the connectors with sandpaper and a file. they were just too smooth for my fingers. adverse weather conditions made the situation worse. I have no trouble now. it sounds like you just need a new battery. this is the one I have now & it's wonderful. I get several rides per charge. I am careful to follow charging directions. I also use an extension wire so it can ride in my rear trunk. but I put it someplace "safe" & I can't find it, so the battery rides on my top tube using the straps provided. very secure. that "brand" has a new website with newer products which have better lenses & beam patterns. I tried the cheap knockoffs but the wires weren't good, so I don't use it. other ppl have had good luck with those but I think they use a flat lens, so the beam pattern is pretty old fashioned. good luck with your new bike!
Magicshine Bike Light Battery, MJ-6102 high Capacity 6 Cell Li-ion Rechargeable Battery for Bike. 7800mah Waterproof Battery for Mountain Bike Lights Round Plug