It says this bug has been resolved but i am still experiencing it regularly.
Mobs enclosed in pens will just escape somehow.
To recreate this just put some mobs in pens (for me sheep are the worst) and then go and do something like find diamonds and then usually one has escaped.
"It says this bug has been resolved "
Please, don't open a new ticket then; Please report in the comments of that ticket that you still experience that bug.