I struggled a long time with this problem. One of the beds in my iron farm was always forgotten about after I came back from the nether. Replacing the beds seemed to fix the problem temporarily most times. Eventually I solved the problem by rebuilding that section of the farm in a different design, which worked for some reason. If the problem occurs again I’ll see if I can contribute with a save or other documentation.
(Btw, the other quadrants of the farm, which were built exactly the same way, had no issues. So the problem is not in the farm design itself).