I’m sure there’s something “nutritional” there for them but?
Biological – there are many species of flies, and many of them specialise in the food of their larvae (maggots). A relatively small number of species feed on feces, which are actually quite nutritional for a whole range of organisms. As they may require fresh poop for breeding, they naturally have a very good sense to smell that – it must really smell yummy to them! :-)
Flies are among the first organisms in a chain of decomposers of organic waste materials, next to some species of beetles. Their larvae chiefly feed on the soft and moist material. Next will be fungi, other flies and beetles, mites (probably feeding on the fungi), springtails, isopods, nematodes, etc., all turning your compost into fertilised soil.
Source: biologist, been closely watching my compost toilet (not a sophisticated type where one would go for minimal fly attraction but made for fast fertiliser production).
Metaphorical – well, in a world where greed is acceptable and exploitation is a norm, bad things attract bad actors (who may also be specialised to metaphorically feed on certain bad stuff) – who will profit from such bad things.
No why aren’t you
It’s like a fetish.
…a very weird one.
You see, it started off with a lot of promises made, like Mexico paying for a wall, lower taxes for the wealthy, etc. then it snowballed into everything said being a dog whistle call-to-arms for all the ignorati racists to use violence against everything and everyone they fear- which essentially meant- everything they didn’t understand, like- freedom of choice, proper education, to everyone they didn’t understand, like the LGBTQ and people of color.
The fly sees it and immediately thinks, “This would be a good place to start a family.”