I find I replace the seals in my M4’s rather more than I’d expected to, (even with clean, unworn pistons) – mine often seem to end up with a piston that either sticks in, or won’t retract properly …
Happily, M4’s do have great spares availability (IME); they strip down fast, go back together properly and bleed through quickly and easily too, in a nice, predictable way, so whilst it’s a bit dull to do it too often, it’s not an especially onerous job. (Fluid smell aside).
If/when you get to the ‘in bits’ stage, see if that piston has picked up a bit of wear – hard to imagine how this happens, given the forces / travel / materials, but it’s something that can cause a bit of leakage, and/or attract ‘muck’ – which can make the piston sticky (more sticky).
I usually end up swapping pistons around between calipers when I’m rebuilding mine, albeit non-deliberately, due to everything being cleaned at the same time.