Genetics
You won't get any more from a plant than it is genetically capable of realizing.
Nutrients
Even with good genetics, without proper nutrition it won'to reach its full potential. One element essential for terpene and cannabinoid synthesis is sulfur. It's not one I see discussed much.
Trimming
Trichomes that contain terpenes are mostly on the leaves. Excessive trimming removes a lot of terps. You lose flavor, nuances of the buzz and, for some like me, most of the medicinal benefits.
Drying
Improper drying can degrade cannabinoids and terpenes. Personally, I think people stress about this too much. I've never had ideal conditions regarding temps, rh or light exposure and have yet to experience any adverse results. These days my plants hang in my living space which is a big art studio. I run a dehumidifier and fans. It seems to suffice. If my weed got LESS potent somehow then it's probably a good thing. Lol
Curing
A good cure brings out more to me. I find that the aroma, taste and effects change over a few months time.
Storage
Once the bud is done evolving, keeping it stored in the right conditions minimizes long term degradation. I grow a year's supply at a time so this is key for me. I use Grove bags that I store in totes.