I would say the most important thing would be a knowlege of your limitations, and how to work around them. So yea, it's definitely all about the knowlege you get from practice and experience.
I'm not so sure that I subscribe to the theory that you have to have awesome songs and great musicians. I can make a really good recording of a crappy song performed by musicians of equally crappy caliber.
You'd probably listen to it and say, "Damn. That's a really good recording of a crappy band and an equally crappy song."
The drummer is an exception to my rule, although I can't put my finger on just why. Neal Peart could probably play his drums in my basement with no engineer, and it would sound like it was recorded by Mutt Lange at Abbey Road. On the other hand, I could play with Mutt at Abbey Road, and it would sound like it was recorded in my basement by a newbie.
Getting back to the crappy musicians thing . . . If you know what you're doing, you can turn a crappy musician in to a good one. Hell, just have him/her record like 100 takes of their part . . . and then use some creative editing to piece together whatever shining moments there might be scattered amongst all the various takes.
If worse comes to worse, you could even find that one magical passage and loop it. Then find another one and loop that. Of course then, you'd pretty much have to loop everything and make it all a loop-based project, but better that than have a more organic one that showcases the crappiness of all the musicians.
I don't have an enormous array of exemplary gear, nor do I have a recording space that people would fight over to record in. But I have a knack for editing . . . and I can take the most average-sounding musicians from off the street and make them sound FAR better than they have any right to sound!