The bacteria in your solution have fed and are off-gassing. They are in the process of dying. The foam is likely full of solids material which is necrotic (dead) bacteria. Once you notice the foaming, take it off aeration to preserve the life of the bacteria. And use the solution as quickly as possible. If you continue to aerate, the bacteria will consume all the oxygen then it becomes a smelly anaerobic soup. The buggies will no longer be interested in the available resources in the soil or on the roots, because they are not hungry anymore. They will expire in the medium and create more necrotic material. Keep those bugs hungry.
Bacteria dominated tea. Fungus dominated soil (root).
(PS when not in use place the air stones in a water bath with hydrogen peroxide. 2 tablespoons to 1/2 gallon water, every few days, depending on use. Keep the pump running. Change water and stones when coated with a mass and air flow becomes restricted.)
Also make sure you are not using too much molasses. Cut back on it to extend aeration time. Add more and continue a short aeration if aact solution starts to become anaerobic.
If not using the solution asap, refrigeration is suggested. Even then, the tea will continue to expire, just slower.