I've never had it happen 3 ranks deep or less. But I have had it happen quite a bit when 4 ranks deep. I've been fiddling with this problem, and I'm beginning to think it has to do with how the program isolates walls from regular ground.

For instance, all units seem to have a default formation of 4 ranks deep for use on walls. Even unit which use horde formation, like peasants, line up nice and neat on walls. If you just right click them on to the wall, no problem. If you drag them 3 ranks or thinner, again, that's OK. But if you compress them into 4 ranks, and then keep going deeper, you will notice that the entire formation shifts one space over, instead of getting another rank deeper (which it can't of course).

I'm thinking this may be a sign of a glitch in how walls are handled by the comp. When the battle starts, you may notice that the 4 rank deep units may all simultaneously back up, or fall down and get up. It looks as if the computer thinks the unit is 5 ranks deep, when it's visually shown as 4 deep. That backstepping and falling motion you see is when the comp realizes this, and attempts to correct the ranks. Whatever is too close to the edge falls off. Since it's a function of all of the men in a unit simultaneously shuffling backwarsds, that also may explain why it this glitch may kill 5 or 50.

There has to be more to it than this, since I haven't been able to repeat it consistently. But that's what I've discovered so far.