While exploring a cave not too far from my house, I heard lightning strike and then the messages "parrot was struck and killed by lightning" appeared. All my animals are in an enclosed cobblestone building with a glass and jungle plank roof. (see attached screenshot). I don't believe lightning should be able to go through any of those blocks.
Linked issues
Attachments
Comments 4

Did one of your parrots disappear/die? Are you sure that all of them were located indoors?
This issue is being temporarily resolved as Awaiting Response. Once the requested information has been delivered, the report will be reopened automatically.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
They didn't disappear, they were all tamed. One died by the lightning (the chat message said so) and two others died from the resulting fire from the strike. I'm 100 percent certain they were all indoors.
Edit: They were also all sitting so they wouldn’t move/fly
Can confirm, affects 1.21.51. This is also an issue on Java. The main culprit here is that lightning can strike entities through glass and stained glass blocks. Note how tinted glass is unaffected by this.
Steps to reproduce:
Equip a trident enchanted with channeling.
Make sure the weather is set to "thunder".
Build a glass platform and summon any mob below it.
Throw the trident at the mob.
Observed results:
The mob will be struck by lightning.
Expected results:
It shouldn't.