it might have frozen, so the caliper failed to return, which would leave the cable slack. ordinarily one would notice that, because of the drag from the stuck caliper. on the e-bike you may have just powered through it. (which would wear the heck out of the pads, which may also explain why you needed to adjust the brakes the next day.)
next time, you could try manually wiggling the caliper to free it up (watch what normally moves when you pull the cable, and push it the other way if it’s stuck)