Pistons fail to retract when any block is under slime.
Related issues
duplicates
Attachments
Comments


"Works by design" per MC-54310
Top sticky piston tries to retract first, so the slime block connects to the grass block. But it's movement is blocked by the bottom (still extended) piston. As a result - the slime block is not moved. Then the bottom sticky piston retracts and moves the grass block.
You can activate the bottom piston first (e.g. my "works" screenshot)

@SunCat should the pistons not try to retract simultaneously?

technically, yes, but the game handles the top piston first to keep the game running instead of stopping, doing calculations, and continuing 20 times a second. (Also, that kind of thing is not guaranteed and difficult to do with java)