There are plenty of organic versions you could use that will not leave a bad taste, you could just flush out the soil before harvesting and make sure all the foliage is washed carefully before eating/consuming. below is some recipes iv used in the past...
Eucalyptus Oil
A great natural pesticide for flies, bees, and wasps. Simply sprinkle a few drops of eucalyptus oil where the insects are found. They will all be gone before you know it.
Salt Spray
For treating plants infested with spider mites, mix two tablespoons of Himalayan Crystal Salt into one gallon of warm water and spray on infected areas.
Onion and Garlic Spray
Mince one organic clove of garlic and one medium sized organic onion. Add to a quart of water. Wait one hour and then add one teaspoon of cayenne pepper and one tablespoon of liquid soap to the mix. This organic spray will hold its potency for one week if stored in the refrigerator.