The bug
Bees freeze if they cannot execute their current AI task and cannot pathfind to their current target, such as a player, a flower, or a bee hive/nest. This is probably the case because bees don't have a wandering AI and completely rely on their current target(s) for pathfinding.
This issue seems to occur in multiple different scenarios:
Bee cannot find a flower or pathfind to a flower
Angry bee cannot pathfind to its attacker (MC-159676)
Bee cannot find a new home hive/nest or cannot pathfind to its home hive/nest, either after having pollinated a flower or after not finding a flower to pollinate
The last case appears to happen most often. It seems like if a bee has not pollinated a flower for a while (about 3600 ticks, maybe a bit more) and does not have a home hive (which happens often, see MC-159418), this issue occurs.
The fact that the bee does not have any animation when being stuck in the air is a client-side issue and also occurs in other circumstances. That issue is tracked in MC-159518.
To reproduce
There are many ways to reproduce this issue, however the most common way this happens is if a bee is too high up in the sky. That case is easily reproducible using the following steps:
Spawn a bee at the top of the world, way above the ground
Follow the bee for a while, until its
TicksSincePollination
value is at least3600
Wait a bit longer
→ ❌ The bee will stand still
Linked issues
is duplicated by 49
relates to 6
Attachments
Comments 28
Here you go:
{NoGravity: 1b, Brain: {memories: {}}, HurtByTimestamp: 0, FlowerPos: {X: 0, Y: 0, Z: 0}, HasStung: 0b, Attributes: [{Base: 10.0d, Name: "generic.maxHealth"}, {Base: 0.0d, Name: "generic.knockbackResistance"}, {Base: 0.30000001192092896d, Name: "generic.movementSpeed"}, {Base: 0.0d, Name: "generic.armor"}, {Base: 0.0d, Name: "generic.armorToughness"}, {Base: 16.0d, Name: "generic.followRange"}, {Base: 0.0d, Name: "generic.attackKnockback"}, {Base: 0.6000000238418579d, Name: "generic.flyingSpeed"}, {Base: 2.0d, Name: "generic.attackDamage"}], Invulnerable: 0b, FallFlying: 0b, ForcedAge: 0, PortalCooldown: 0, AbsorptionAmount: 0.0f, FallDistance: 0.0f, InLove: 0, DeathTime: 0s, HandDropChances: [0.085f, 0.085f], CannotEnterHiveTicks: 0, PersistenceRequired: 0b, Age: 0, TicksSincePollination: 33872, Anger: 0, Motion: [0.0d, 0.0d, 0.0d], Health: 8.0f, HurtBy: "512419b6-e5d9-422b-a13f-98444e576e38", HasNectar: 0b, LeftHanded: 0b, Air: 300s, OnGround: 0b, Rotation: [20.729439f, 0.0f], HandItems: [{}, {}], ArmorDropChances: [0.085f, 0.085f, 0.085f, 0.085f], Fire: -1s, ArmorItems: [{}, {}, {}, {}], CropsGrownSincePollination: 0, CanPickUpLoot: 0b, HurtTime: 0s, HivePos: {X: 0, Y: 0, Z: 0}}
How do u copy the command output? I got the same behaviour on a bee and want to help 🙂
I couldn't copy it from chat or a command block output, but if you look at the bee and press F3 + i you'll copy the exact same data to the clipboard 🙂
Thanks 😃 Here is my bee
{NoGravity: 1b, Brain: {memories: {}}, HurtByTimestamp: 0, FlowerPos: {X: 0, Y: 0, Z: 0}, HasStung: 0b, Attributes: [{Base: 10.0d, Name: "generic.maxHealth"}, {Base: 0.0d, Name: "generic.knockbackResistance"}, {Base: 0.30000001192092896d, Name: "generic.movementSpeed"}, {Base: 0.0d, Name: "generic.armor"}, {Base: 0.0d, Name: "generic.armorToughness"}, {Base: 16.0d, Modifiers: [{UUIDMost: 2153429020781006355L, UUIDLeast: -8744511316061402533L, Amount: 0.011939049796697743d, Operation: 1, Name: "Random spawn bonus"}], Name: "generic.followRange"}, {Base: 0.0d, Name: "generic.attackKnockback"}, {Base: 0.6000000238418579d, Name: "generic.flyingSpeed"}, {Base: 2.0d, Name: "generic.attackDamage"}], Invulnerable: 0b, FallFlying: 0b, ForcedAge: 0, PortalCooldown: 0, AbsorptionAmount: 0.0f, FallDistance: 0.0f, InLove: 0, DeathTime: 0s, HandDropChances: [0.085f, 0.085f], CannotEnterHiveTicks: 0, PersistenceRequired: 0b, Age: 0, TicksSincePollination: 27613, Anger: 0, Motion: [0.0d, 0.0d, 0.0d], Health: 10.0f, HurtBy: "", HasNectar: 0b, LeftHanded: 0b, Air: 300s, OnGround: 0b, Rotation: [324.48358f, 0.0f], HandItems: [{}, {}], ArmorDropChances: [0.085f, 0.085f, 0.085f, 0.085f], Fire: -1s, ArmorItems: [{}, {}, {}, {}], CropsGrownSincePollination: 0, CanPickUpLoot: 0b, HurtTime: 0s, HivePos: {X: 149, Y: 65, Z: -405}}
Tbh I compared it with a normal functional bee and there is no difference at all
@unknown, 19w41a is already marked as affected.

I still cannot reproduce given the steps provided - a world save would be extremely helpful in bringing me closer to solving this. One note - AI stops functioning below y=0 and acts weird above y = 255. I see one example posted is between those values, but most of the examples given are about bees going above or below the world height limits, which is not really a valid use case / test case.
I've attached a world I used to reproduce this issue to this ticket. Also, I recorded a short video of this issue, which you can watch here: https://youtu.be/ZpfFTlzL7Co
As you can see, the bee is never above 255 or below 0, but the void world was just used as a case to demonstrate that this happens whenever a bee doesn't find its target for a while. This should work in a regular world without any flowers and without any bee hives as well.
Can confirm this happens below y = 255, this behavior tends to be triggered frequently after a bee leaves their home unexpectedly (Ex. taking the honey or honeycombs from the hives/nests), but this can still happen in both ways (Naturally without any provocation or due to the explanation I gave previously)
Basically instead of aim towards a flower they begin to fly very high till the point is impossible for them to track a flower due to the pathfinding limitations, that's why this bug gets reproduced in most cases by a bee without pollen, can confirm too this is not the case if a bee already has pollen + is far away from the home, they can track their home back from a decent amount of far blocks.
[media]

Thanks for the info and world save, that really helped in tracking this down!
Can you run
/data get entity @e[type=bee,distance=..5,limit=1]
while near the bee and post the result here?