There's an infrared beam and sensor. When the ice tray is full, it is supposed to block the beam, and then the machine stops making ice.
On a sunny day, there's enough bright light in our kitchen to fool the sensor so it keeps making ice.
We have a random magazine that we put on top of it to make it work correctly.