Try herbal sprays against any leaf-eating pests and make note of what works for future reference. Oor you can make a herbal tea by pouring the same amount of boiling water over 2 to 4 cups fresh or 1 to 2 cups dry leaves and leaving them to steep until cool. Strain the water through a cheesecloth before spraying and dilute further with 2 to 4 cups water. You can also buy commercial essential herbal oils and dilute with water to make a spray. Experiment with proportions, starting with a few drops of oil per cup of water.
Synthetic capsaicin is also available for feild use.
Capsaicin-containing dusts repel onion maggots from seedlings, as well as other root maggot flies from cabbage family plants and carrots. Pepper dusts around the base of the plants help repel ants, which is desirable in a garden where ants often protect and maintain aphid colonies on plants. However, if you grow and dry your own red peppers, chili peppers, or dill, you can make lots of dust at low cost. Use a mortar and pestle to grind the peppers, or dill, including the seeds, to dust. Be careful handling the hot peppers because they irritate sensitive skin.