A fun experiment a few years back:
Pretty sure I picked up gnats from some organic amended pre bagged coco from the grow store.
Kept having flyers land on my face, and would get annoyed and blow huge vape clouds at them. They would fly off and land on the wall, high af from the nicotine i'm sure. Eventually I would start blowing vape all over the plants, because the vegetable glycerin would leave a slight film of residuals.
It was working to keep the flyers at bay, but I realized I was infested and had larva too.
Used one of the worst looking plants to mess around with.. and let her dry out for a day or 2.
That's when I busted out my new secret weapon to test.
Super high mg nicotine/peppermint flavored E-cig juice, pumped right into the dried out coco through a straw.
All the flyers and larva immediately came to the surface and died.
Flushed the plant good after words and it lived. No more gnats, lol.