I was getting gnats from my bin so ended up putting a piece of fine silk screen mesh over the top of the worm bin secured by a bungee cord. Now they fly around in there trying to find the way out until they give up, die and, their carcasses soon become tiny morsels of food for worms/fungi. The circle of life...