Yeah, with sufficient unthoughtfulness, refusing to do research, and with poor enough planning, you can fuck up literally anything? I’m not sure what your point is. I didn’t say it was suitable for everybody, or that it magically cannot fail, or that it will always be worth it in all circumstances (if your soil’s contaminated, yes, you will want to be careful about how you garden and your costs will likely be higher), or that gardening, unlike anything else, is a good fit for everybody’s brain and that every single person can do it effectively.
I just think it’s kinda dumb to go after home gardening as somehow not useful or valuable just because it’s not a complete, viable replacement for industrial agriculture. It’s a completely stupid false dichotomy.
Basically you need to think about how to do it cost-effectively and sanely. Just like anything else you do (you do think about that, right?)