Slavery needed cheap land, in order to maintain its economic viability. A free man, working his own land, would be much more industrious than a slave who only worked as hard as he had to, and take every opportunity to goof off. As the country filled up, free men would drive up the price of land. If slaves were not economically viable, then their price would drop to nothing.
It needed not only cheap land, it needed land capable of growing cash crops which required a lot of labor. Mechanical harvesting systems for grains had already been developed, and so labor was not so significant for such crops. It was however necessary (at the time) for the most significant cash crop of that era; Cotton.
The land in the territories was not capable of growing Cotton. Therefore slavery would have never flourished in any of the territories.
A free man, working his own land, would be much more industrious than a slave who only worked as hard as he had to, and take every opportunity to goof off. As the country filled up, free men would drive up the price of land. If slaves were not economically viable, then their price would drop to nothing.
Which is exactly what would have happened eventually. Slavery would have abolished itself given another 20-80 years. Those wishing to hurry it along only caused more bloodshed and much disaster.