It's happened to me too. It's a bug that kills you without reason. The death message usually says that you killed by an angry enderman, but sometimes it says that the player died because of commands or a projectile. I think it's probably a tick error.
Yeah, I figured it out. It was an issue with flower generating. When it generated flowers, sometimes it would generate flower with a blank block id. And whenever you touched one of these you would die instantly