Updated description by @unknown
Steps to reproduce
Enchant a trident with channeling.
/weather thunder
Kill mobs and players by throwing the trident at them.
Expected result
Mobs give their normal drops. Players drop their entire inventory.
Actual result
No player or mob drops anything.
Original description
When using a trident during a thunderstorm with channeling on a player, it removed all of his items including armor, tools, and weapons. I tried looking for his items everywhere around the location, but couldn't find them. I did a test once again and he lost his items again.
Related issues
Comments

Thank you for your report!
However, this issue has been temporarily closed as Awaiting Response
Is this still an issue in the latest version? If so, please make sure the ticket description contains the following information:
Steps to Reproduce:
1.
2.
3.Observed Results:
(Briefly describe what happens)Expected Results:
(Briefly describe what should happen)
If your ticket does not look like the example given here, then it's likely to be closed as incomplete.
This ticket will automatically reopen when you reply.
Quick Links:
📓 Issue Guidelines – 💬 Mojang Support – 📧 Suggestions – 📖 Minecraft Wiki

Still an issue.

I can still reproduce this in 1.20.30 & 1.20.40.22, I would like to request ownership of this report since this issue has not been updated in over 2 years but is still present.

To fix this bug, item entities need an 8 tick invulnerability from lightning when they first spawn in the world.

Thank you for your report!
After consideration, the issue is being closed as Working as Intended.
Please note, that mechanics of the game may change between updates.
Things such as graphics, sounds, world creation, biomes, redstone, villagers, and animals may not work the same in current versions.
Full Version History – Snapshot Version History – Feature Requests and Suggestions
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki
This is probably due to the fact that lightning destroys item entities. The lightning from channeling probably occurs one tick later than the hit and therefore after the kill and item drops.