Duplicate of https://screeps.com/forum/topic/2756. It happens quite often for me. It drives me nuts, but I haven't found any way to reproduce it so it's anyone's guess what the cause is.