The bug
When a pufferfish is near an armor stand, the fish will inflate even though the armor stand is an inanimate object.
Code analysis
(based on Yarn 20w15a mappings)
The AI goal that causes pufferfish to inflate takes nearby entities that are instances of LivingEntity and calls a predicate function that filters out Creative/Spectator mode players and water mobs. However, armor stands also extend LivingEntity and therefore get included.
It seems fairly simple to filter out instances of armor stands as well, or test the isMobOrPlayer()
function (where armor stands return false, but all other LivingEntities return true).
Related issues
relates to
Attachments
Comments


Relates to MC-129884
It is just scared because the armor stand looks so human 😃

Don't think this is a bug; the fish detects an object which is similar to the "human" and sets the "Defensive Mode".

do anybody have anything that confirmes that the pufferfish act like this towards armorstands are right, and not a bug? not pointing fingers, just asking

Confirmed
The pufferfish is the most scared mob in the game