Fix note Fix note: This has only been fixed for wolves as they spawn as friendlies. Ocelots spawn as monsters (i.e. continously) and need to be despawned when inactive. Source

I created a survival file and started playing. I found some wolves and caged them so they didn't run off until I got some bones. I did not tame them, and for some reason, after unloading the chunk, they disappeared.

To reproduce:

Create a new world with no generation modifications. Find some wolves and trap them. Make note of their location. Wander off until the chunk is no longer loaded (>16 chunks). Go back and the wolves should've despawned.

the code affected