If the death cause wasn’t a player or NPC, it could likely have been temperature related.
Death due to overheating while sleeping happens more frequently than not due to players sleeping close to heat sources, and do note that base location and foundations also play a role in this.
Besides putting all your equipment and inventory in a chest, it’s also a good idea to check if your character is experiencing any temperature effects before logging out.
Ideally, if you are able to reproduce this issue consistently, please share the location, a few screenshots of the area and position to logout, and any detailed steps to take, so that we can share this data with the QA team for further investigation.