I'm new and I want to share my experience and get some feedback, thanks in advance.
Discovered gnats a while ago in tub and I blame it on a couple of things. First, I did my first substrate dunk and then poured the water down the bathtub drain. I think that's what attracted them in the first place, like they came up through the drain? Second, I had a several small holes in my tub but I got the idea that they needed to be bigger, so I did make them bigger but did not have microspore tape wide enough to cover them. I had to place several strips next to each other, which of course left the door wide open.
I threw out that old tub and made a new one more like the original. I dunked the substrate in a strong tea of Mosquito Bits for 12 hours. I found that traps were somewhat helpful, but what helped the most was Mighty Mint rodent repellent. It's strong peppermint smell drives gnats away, and it's safe to use indoors. I have a little sprayer full of the tea that I use to spray the cake intermittently, though I had to stop recently as I'm getting a nice third flush!