Heroes somehow drop gold at gates in home realms
When you summon heroes in home realms (both), there is a chance that a pile of gold will appear within the area of heroes gates. You can pick gold from the sacred earth piece before the gates, but you can't pick it from the gates, and workers can't pick it too. At first I thought it happens because miners get killed by defenses right after they spawned. But then I moved away all defenses, and never attacked heroes until they move far enough from the gates. And yet it still happens sometimes, right after summoning heroes a new pile of unobtainable gold appears at the gates. My guess is when the game creates heroes and gives them random amount of gold, it may exceed their capability to carry it, so they drop it.
A gold pile has a chance to appear even if no one dies there. Right when the gates create heroes.
So I suppose some kind of error might be there after all, not just a game design issue.