Villagers won't detect a bed in a covered environment if there's a door on their way.
The bug first appeared in a normal situation as shown on the 3 first screenshots. I broke the door and problem solved.
So I made a glass test thing and it confirms the bug.
Therefore, villagers doesn't sleep at night. They also seem not to go out during daytime..
Steps to reproduce: set your time to night time, make a covered room with a bed and a door, spawn a villager next to the structure: the villager won't go sleeping.
Linked issues
is duplicated by
relates to
Attachments
Comments

Does this still happen in 1.14.1 Pre-Release 2?

Can't reproduce. Presume fixed with doors issue.

Seems problem solved in 1.14.1 Pre-Release 2.

No, not resolved.
Villagers still take the quickest Path to their beds even if the bed is surrounded by blocks and there is a door a few blocks away.
villagers end up trying to pathfind through walls continuously until the bed is unclaimed.
same for job blocks.
only way I managed to fix this is making extra doors, but then the houses look bad with 4 doors, one on each side

Apparently it’s an ai limitation, however I have my doubts
can reproduce