Is there a way to manually install modules for python?
<p>I keep running into problems with installing modules for python. Either because the modules themselves aren't able to be downloaded via pip or because of some error or another. </p>

<p>Is it possible to simply download the module as a .zip or tar.gz file (as I see a lot of links to do just that) and then somehow place them within the file that Python uses to store its modules (I think it's the Lib folder).</p>

<p>Is this possible? What are the pitfalls for doing something like this? </p>

<p>As you noticed, you can download a module's source (usually in the form of a <code>.tar.gz</code> archive) from <a href="https://pypi.python.org" rel="nofollow">PyPI</a>. First, unpack the archive, then enter the folder that is created. Assuming that your Python binary is on your path, simply run</p>

<pre><code>python setup.py install
</code></pre>

<p>or (for Python 3)</p>

<pre><code>python3 setup.py install
</code></pre>

<p>and it will be built and installed. Of course, if the module contains extensions written in C/C++ that need to be compiled, you'll need to have a compiler installed and configured on your system, along with any requisite libraries.</p>

<p>If you're on Windows, you can find pre-compiled <code>.whl</code>s for many packages <a href="http://www.lfd.uci.edu/~gohlke/pythonlibs/" rel="nofollow">here</a>.</p>

<p>Details about all of this are easily available by googling. </p>

python module install