ipython3 and jupyter notebook not allowing python3 opition - python

Okay, I know I am probably going to receive a cluster of down votes after having been unable to solve this issue, but I am fairly new to python and jupyter notebook. So far I have only been able to use python3 with jupyter notebook once upon initial set up and ever since then it has defied all logic and despite ipython being the backend of jupyter notebook, stating it no longer supports python2 like some progressive and want's nothing to do with pyhton2 anymore; python2 is bunked down in my notebook like the Russians at Stalingrad and I fear I may not be able to drive the Bolshevik out.
So like a good little boy I make my own venv environment and try and install ipython for python3 [you know - the only version that matters according to their website]:
main#McCarter:~/Desktop
$ sudo python3 -m venv /Documents/Intro-to-Pandas
main#McCarter:~/Desktop
$ source /Documents/Intro-to-Pandas/bin/activate
(Intro-to-Pandas) main#McCarter:~/Desktop
$ python3 -m pip --version
pip 9.0.1 from /Documents/Intro-to-Pandas/lib/python3.5/site-packages (python 3.5)
(Intro-to-Pandas) main#McCarter:~/Desktop
$ python3 -m pip install ipykernel
After which I receive errors which I root down to being an issue with installing tornado. SO I try installing tornado with pip and sudo apt install. I even try installing the infamous anaconda, a program who's developers I am sure take great pride in their software destroying all paths and being akin to the Manhattan project to set up:
(Intro-to-Pandas) main#McCarter:~/Desktop
$ python3 -m pip install ipykernel
Collecting ipykernel
Using cached https://files.pythonhosted.org/packages/d8/b0/f0be5c5ab335196f5cce96e5b889a4fcf5bfe462eb0acc05cd7e2caf65eb/ipykernel-5.1.0-py3-none-any.whl
Collecting tornado>=4.2 (from ipykernel)
Using cached https://files.pythonhosted.org/packages/b1/7f/8109821ff9df1bf3519169e34646705c32ac13be6a4d51a79ed57f47686e/tornado-6.0.1.tar.gz
Collecting traitlets>=4.1.0 (from ipykernel)
Using cached https://files.pythonhosted.org/packages/93/d6/abcb22de61d78e2fc3959c964628a5771e47e7cc60d53e9342e21ed6cc9a/traitlets-4.3.2-py2.py3-none-any.whl
Collecting jupyter-client (from ipykernel)
Using cached https://files.pythonhosted.org/packages/3b/c3/3043fe9ffd140d03c9d091a056794ccdc427c56ec19b8eea74f9ea0a498f/jupyter_client-5.2.4-py2.py3-none-any.whl
Collecting ipython>=5.0.0 (from ipykernel)
Using cached https://files.pythonhosted.org/packages/46/b5/ca080401b8dbde51a0f4377b4e22ce02b266340a1cda389b6dea702d06d1/ipython-7.4.0-py3-none-any.whl
Collecting decorator (from traitlets>=4.1.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/5f/88/0075e461560a1e750a0dcbf77f1d9de775028c37a19a346a6c565a257399/decorator-4.4.0-py2.py3-none-any.whl
Collecting six (from traitlets>=4.1.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/73/fb/00a976f728d0d1fecfe898238ce23f502a721c0ac0ecfedb80e0d88c64e9/six-1.12.0-py2.py3-none-any.whl
Collecting ipython-genutils (from traitlets>=4.1.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/fa/bc/9bd3b5c2b4774d5f33b2d544f1460be9df7df2fe42f352135381c347c69a/ipython_genutils-0.2.0-py2.py3-none-any.whl
Collecting python-dateutil>=2.1 (from jupyter-client->ipykernel)
Using cached https://files.pythonhosted.org/packages/41/17/c62faccbfbd163c7f57f3844689e3a78bae1f403648a6afb1d0866d87fbb/python_dateutil-2.8.0-py2.py3-none-any.whl
Collecting jupyter-core (from jupyter-client->ipykernel)
Using cached https://files.pythonhosted.org/packages/1d/44/065d2d7bae7bebc06f1dd70d23c36da8c50c0f08b4236716743d706762a8/jupyter_core-4.4.0-py2.py3-none-any.whl
Collecting pyzmq>=13 (from jupyter-client->ipykernel)
Using cached https://files.pythonhosted.org/packages/39/7a/9b98aabbde03fc4c5c38079ddec1331af3846d80c0b73bdb691a21adee9c/pyzmq-18.0.1-cp35-cp35m-manylinux1_x86_64.whl
Collecting pickleshare (from ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/9a/41/220f49aaea88bc6fa6cba8d05ecf24676326156c23b991e80b3f2fc24c77/pickleshare-0.7.5-py2.py3-none-any.whl
Collecting pygments (from ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/13/e5/6d710c9cf96c31ac82657bcfb441df328b22df8564d58d0c4cd62612674c/Pygments-2.3.1-py2.py3-none-any.whl
Collecting backcall (from ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/84/71/c8ca4f5bb1e08401b916c68003acf0a0655df935d74d93bf3f3364b310e0/backcall-0.1.0.tar.gz
Collecting jedi>=0.10 (from ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/25/2b/1f188901be099d52d7b06f4d3b7cb9f8f09692c50697b139eaf6fa2928d8/jedi-0.13.3-py2.py3-none-any.whl
Collecting prompt-toolkit<2.1.0,>=2.0.0 (from ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/f7/a7/9b1dd14ef45345f186ef69d175bdd2491c40ab1dfa4b2b3e4352df719ed7/prompt_toolkit-2.0.9-py3-none-any.whl
Collecting pexpect; sys_platform != "win32" (from ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/89/e6/b5a1de8b0cc4e07ca1b305a4fcc3f9806025c1b651ea302646341222f88b/pexpect-4.6.0-py2.py3-none-any.whl
Requirement already satisfied: setuptools>=18.5 in /Documents/Intro-to-Pandas/lib/python3.5/site-packages (from ipython>=5.0.0->ipykernel)
Collecting parso>=0.3.0 (from jedi>=0.10->ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/19/b1/522b2671cc6d134c9d3f5dfc0d02fee07cab848e908d03d2bffea78cca8f/parso-0.3.4-py2.py3-none-any.whl
Collecting wcwidth (from prompt-toolkit<2.1.0,>=2.0.0->ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/7e/9f/526a6947247599b084ee5232e4f9190a38f398d7300d866af3ab571a5bfe/wcwidth-0.1.7-py2.py3-none-any.whl
Collecting ptyprocess>=0.5 (from pexpect; sys_platform != "win32"->ipython>=5.0.0->ipykernel)
Using cached https://files.pythonhosted.org/packages/d1/29/605c2cc68a9992d18dada28206eeada56ea4bd07a239669da41674648b6f/ptyprocess-0.6.0-py2.py3-none-any.whl
Building wheels for collected packages: tornado, backcall
Running setup.py bdist_wheel for tornado ... error
Complete output from command /Documents/Intro-to-Pandas/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-jgyop2hc/tornado/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmpj4fqywe1pip-wheel- --python-tag cp35:
usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: -c --help [cmd1 cmd2 ...]
or: -c --help-commands
or: -c cmd --help
error: invalid command 'bdist_wheel'
----------------------------------------
Failed building wheel for tornado
Running setup.py clean for tornado
Running setup.py bdist_wheel for backcall ... error
Complete output from command /Documents/Intro-to-Pandas/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-jgyop2hc/backcall/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmps7t3djcqpip-wheel- --python-tag cp35:
usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: -c --help [cmd1 cmd2 ...]
or: -c --help-commands
or: -c cmd --help
error: invalid command 'bdist_wheel'
----------------------------------------
Failed building wheel for backcall
Running setup.py clean for backcall
Failed to build tornado backcall
Installing collected packages: tornado, decorator, six, ipython-genutils, traitlets, python-dateutil, jupyter-core, pyzmq, jupyter-client, pickleshare, pygments, backcall, parso, jedi, wcwidth, prompt-toolkit, ptyprocess, pexpect, ipython, ipykernel
Running setup.py install for tornado ... error
Complete output from command /Documents/Intro-to-Pandas/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-jgyop2hc/tornado/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-j9jy0w7y-record/install-record.txt --single-version-externally-managed --compile --install-headers /Documents/Intro-to-Pandas/include/site/python3.5/tornado:
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.5
creating build/lib.linux-x86_64-3.5/tornado
copying tornado/util.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/wsgi.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/log.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/options.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/testing.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/curl_httpclient.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/web.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/netutil.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/http1connection.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/locale.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/concurrent.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/_locale_data.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/ioloop.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/iostream.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/__init__.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/websocket.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/auth.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/httputil.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/httpserver.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/tcpserver.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/tcpclient.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/autoreload.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/process.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/httpclient.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/template.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/locks.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/queues.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/escape.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/simple_httpclient.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/routing.py -> build/lib.linux-x86_64-3.5/tornado
copying tornado/gen.py -> build/lib.linux-x86_64-3.5/tornado
creating build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/util.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/log_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/tcpserver_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/locale_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/resolve_test_helper.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/httpserver_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/import_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/util_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/escape_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/iostream_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/simple_httpclient_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/template_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/locks_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/routing_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/queues_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/__init__.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/options_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/testing_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/wsgi_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/netutil_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/runtests.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/gen_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/twisted_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/curl_httpclient_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/asyncio_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/websocket_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/__main__.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/ioloop_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/concurrent_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/tcpclient_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/windows_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/httpclient_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/process_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/auth_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/autoreload_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/httputil_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/web_test.py -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/http1connection_test.py -> build/lib.linux-x86_64-3.5/tornado/test
creating build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/twisted.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/caresresolver.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/interface.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/__init__.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/windows.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/posix.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/auto.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/platform/asyncio.py -> build/lib.linux-x86_64-3.5/tornado/platform
copying tornado/py.typed -> build/lib.linux-x86_64-3.5/tornado
creating build/lib.linux-x86_64-3.5/tornado/test/csv_translations
copying tornado/test/csv_translations/fr_FR.csv -> build/lib.linux-x86_64-3.5/tornado/test/csv_translations
creating build/lib.linux-x86_64-3.5/tornado/test/gettext_translations
creating build/lib.linux-x86_64-3.5/tornado/test/gettext_translations/fr_FR
creating build/lib.linux-x86_64-3.5/tornado/test/gettext_translations/fr_FR/LC_MESSAGES
copying tornado/test/gettext_translations/fr_FR/LC_MESSAGES/tornado_test.mo -> build/lib.linux-x86_64-3.5/tornado/test/gettext_translations/fr_FR/LC_MESSAGES
copying tornado/test/gettext_translations/fr_FR/LC_MESSAGES/tornado_test.po -> build/lib.linux-x86_64-3.5/tornado/test/gettext_translations/fr_FR/LC_MESSAGES
copying tornado/test/options_test.cfg -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/options_test_types.cfg -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/options_test_types_str.cfg -> build/lib.linux-x86_64-3.5/tornado/test
creating build/lib.linux-x86_64-3.5/tornado/test/static
copying tornado/test/static/robots.txt -> build/lib.linux-x86_64-3.5/tornado/test/static
copying tornado/test/static/sample.xml -> build/lib.linux-x86_64-3.5/tornado/test/static
copying tornado/test/static/sample.xml.gz -> build/lib.linux-x86_64-3.5/tornado/test/static
copying tornado/test/static/sample.xml.bz2 -> build/lib.linux-x86_64-3.5/tornado/test/static
creating build/lib.linux-x86_64-3.5/tornado/test/static/dir
copying tornado/test/static/dir/index.html -> build/lib.linux-x86_64-3.5/tornado/test/static/dir
copying tornado/test/static_foo.txt -> build/lib.linux-x86_64-3.5/tornado/test
creating build/lib.linux-x86_64-3.5/tornado/test/templates
copying tornado/test/templates/utf8.html -> build/lib.linux-x86_64-3.5/tornado/test/templates
copying tornado/test/test.crt -> build/lib.linux-x86_64-3.5/tornado/test
copying tornado/test/test.key -> build/lib.linux-x86_64-3.5/tornado/test
running build_ext
building 'tornado.speedups' extension
creating build/temp.linux-x86_64-3.5
creating build/temp.linux-x86_64-3.5/tornado
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fdebug-prefix-map=/build/python3.5-3.5.3=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/Documents/Intro-to-Pandas/include -I/usr/include/python3.5m -c tornado/speedups.c -o build/temp.linux-x86_64-3.5/tornado/speedups.o
tornado/speedups.c:2:20: fatal error: Python.h: No such file or directory
#include <Python.h>
^
compilation terminated.
command 'x86_64-linux-gnu-gcc' failed with exit status 1
/tmp/pip-build-jgyop2hc/tornado/setup.py:104: UserWarning:
********************************************************************
WARNING: The tornado.speedups extension module could not
be compiled. No C extensions are essential for Tornado to run,
although they do result in significant speed improvements for
websockets.
The output above this warning shows how the compilation failed.
Here are some hints for popular operating systems:
If you are seeing this message on Linux you probably need to
install GCC and/or the Python development package for your
version of Python.
Debian and Ubuntu users should issue the following command:
$ sudo apt-get install build-essential python-dev
RedHat and CentOS users should issue the following command:
$ sudo yum install gcc python-devel
Fedora users should issue the following command:
$ sudo dnf install gcc python-devel
MacOS users should run:
$ xcode-select --install
********************************************************************
"The output above "
running install_lib
creating /Documents/Intro-to-Pandas/lib/python3.5/site-packages/tornado
error: could not create '/Documents/Intro-to-Pandas/lib/python3.5/site-packages/tornado': Permission denied
----------------------------------------
Command "/Documents/Intro-to-Pandas/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-jgyop2hc/tornado/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-j9jy0w7y-record/install-record.txt --single-version-externally-managed --compile --install-headers /Documents/Intro-to-Pandas/include/site/python3.5/tornado" failed with error code 1 in /tmp/pip-build-jgyop2hc/tornado/
I know this has something to do with tornado.
sudo python3 -m pip install ipykernel
The directory '/home/main/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/main/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting ipykernel
Downloading https://files.pythonhosted.org/packages/d8/b0/f0be5c5ab335196f5cce96e5b889a4fcf5bfe462eb0acc05cd7e2caf65eb/ipykernel-5.1.0-py3-none-any.whl (113kB)
100% |████████████████████████████████| 122kB 1.5MB/s
Collecting ipython>=5.0.0 (from ipykernel)
Downloading https://files.pythonhosted.org/packages/46/b5/ca080401b8dbde51a0f4377b4e22ce02b266340a1cda389b6dea702d06d1/ipython-7.4.0-py3-none-any.whl (769kB)
100% |████████████████████████████████| 778kB 1.5MB/s
Collecting tornado>=4.2 (from ipykernel)
Downloading https://files.pythonhosted.org/packages/b1/7f/8109821ff9df1bf3519169e34646705c32ac13be6a4d51a79ed57f47686e/tornado-6.0.1.tar.gz (481kB)
100% |████████████████████████████████| 491kB 1.5MB/s
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
ImportError: No module named 'setuptools'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-sr9q5mjc/tornado/
I know I may have to buy a new computer and maybe move to another state after installing anaconda to get this to work.
$ pip install tornado
Collecting tornado
Using cached https://files.pythonhosted.org/packages/b1/7f/8109821ff9df1bf3519169e34646705c32ac13be6a4d51a79ed57f47686e/tornado-6.0.1.tar.gz
Building wheels for collected packages: tornado
Running setup.py bdist_wheel for tornado ... error
Complete output from command /Documents/Intro-to-Pandas/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-ccief454/tornado/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmpg_2iu1zvpip-wheel- --python-tag cp35:
usage: -c [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: -c --help [cmd1 cmd2 ...]
or: -c --help-commands
or: -c cmd --help
error: invalid command 'bdist_wheel'
----------------------------------------
Failed building wheel for tornado
I also sudo apt install'd python-dev and buildessentials. Still did not help.
I just want to know why it's not working - for the sack of knowing.
Command "/Documents/Intro-to-Pandas/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-h1d5rcar/tornado/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-ift0i4ks-record/install-record.txt --single-version-externally-managed --compile --install-headers /Documents/Intro-to-Pandas/include/site/python3.5/tornado" failed with error code 1 in /tmp/pip-build-h1d5rcar/tornado/
(Intro-to-Pandas) main#McCarter:~/Desktop
$ sudo pip install tornado
Traceback (most recent call last):
File "/usr/bin/pip", line 9, in <module>
from pip import main
ImportError: cannot import name main
(Intro-to-Pandas) main#McCarter:~/Desktop
$ sudo pip -m install tornado
Traceback (most recent call last):
File "/usr/bin/pip", line 9, in <module>
from pip import main
ImportError: cannot import name main
(Intro-to-Pandas) main#McCarter:~/Desktop

I fixed my issue(s).
/* Create a python3 virtual enviroment and then using jupyter notebook.*/
$ sudo python3 -m pip install virtualenv :
$ virtualenv mypythonAMCO : //create
$ source mypython/bin/activate : //activate
$ pip install jupyter : //install jupyter
/*Whenever you would like to stop the Jupyter Notebook process, press CTRL+C, type Y when prompted, and then hit ENTER to confirm.*/
I uninstalled anaconda and followed the above, making a virtualenv python environment so as to isolate my 'coding area' in that only the files/modules and version of python I wish will run and be implemented. Making a python virtual environment is very helpful for it gives you more control. I was able to use pip with 'python3 emphasis' to install pandas and start up jupyter notebook.

Related

How does one install torchmeta for a ppc64le architecture in pytorch?

I was trying to use torchmeta in a ppc64le architecture. Unfortunately it's not been easy to install since ppc64le requires special binaries to work.
I eventually managed to get the right binaries for pytorch and torchvision by following these instructions (that prepend the right ibm channel with the conda binaries, plus installs all the required files too):
conda config --prepend channels https://public.dhe.ibm.com/ibmdl/export/pub/software/server/ibm-ai/conda/
conda create -n my_new_env python=3.7 powerai=1.7.0
conda activate my_new_env
after that I proceeded to install the right version of torchmeta, which was 1.3.1 since ppc64le only has pytorch 1.3.1 and torchvision 0.4.2. So I did:
pip install torchmeta==1.3.1
but now I have a new error that it cannot find the right version of h5py compatible with what I want to do. The error message is to large to paste but I will paste what I hope are useful part of it:
(my_new_env) [miranda9#hal-login ~]$ pip install torchmeta==1.3.1
Collecting torchmeta==1.3.1
Using cached torchmeta-1.3.1-py3-none-any.whl (144 kB)
Requirement already satisfied: requests in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from torchmeta==1.3.1) (2.22.0)
Requirement already satisfied: torchvision<0.6.0,>=0.4.0 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from torchmeta==1.3.1) (0.4.2)
Requirement already satisfied: torch<1.5.0,>=1.3.0 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from torchmeta==1.3.1) (1.3.1)
Processing ./.cache/pip/wheels/87/f5/ad/9f04a48453875e8054c19f9fe3f50cbbe0c09b956835555019/Pillow-6.2.2-cp37-cp37m-linux_ppc64le.whl
Requirement already satisfied: numpy>=1.14.0 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from torchmeta==1.3.1) (1.17.4)
Requirement already satisfied: tqdm>=4.0.0 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from torchmeta==1.3.1) (4.36.1)
Collecting h5py~=2.9.0
Using cached h5py-2.9.0.tar.gz (287 kB)
Requirement already satisfied: chardet<3.1.0,>=3.0.2 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from requests->torchmeta==1.3.1) (3.0.4)
Requirement already satisfied: certifi>=2017.4.17 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from requests->torchmeta==1.3.1) (2020.6.20)
Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from requests->torchmeta==1.3.1) (1.25.10)
Requirement already satisfied: idna<2.9,>=2.5 in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from requests->torchmeta==1.3.1) (2.8)
Requirement already satisfied: six in ./.conda/envs/my_new_env/lib/python3.7/site-packages (from torchvision<0.6.0,>=0.4.0->torchmeta==1.3.1) (1.13.0)
Building wheels for collected packages: h5py
Building wheel for h5py (setup.py) ... error
ERROR: Command errored out with exit status 1:
command: /home/miranda9/.conda/envs/my_new_env/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-bpmeop26/h5py/setup.py'"'"'; __file__='"'"'/tmp/pip-install-bpmeop26/h5py/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-ccg1oj0n
cwd: /tmp/pip-install-bpmeop26/h5py/
Complete output (1321 lines):
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-ppc64le-3.7
creating build/lib.linux-ppc64le-3.7/h5py
copying h5py/__init__.py -> build/lib.linux-ppc64le-3.7/h5py
copying h5py/h5py_warnings.py -> build/lib.linux-ppc64le-3.7/h5py
copying h5py/highlevel.py -> build/lib.linux-ppc64le-3.7/h5py
copying h5py/ipy_completer.py -> build/lib.linux-ppc64le-3.7/h5py
copying h5py/version.py -> build/lib.linux-ppc64le-3.7/h5py
creating build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/__init__.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/attrs.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/base.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/compat.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/dataset.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/datatype.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/dims.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/files.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/filters.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/group.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/selections.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/selections2.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
copying h5py/_hl/vds.py -> build/lib.linux-ppc64le-3.7/h5py/_hl
creating build/lib.linux-ppc64le-3.7/h5py/tests
copying h5py/tests/__init__.py -> build/lib.linux-ppc64le-3.7/h5py/tests
copying h5py/tests/common.py -> build/lib.linux-ppc64le-3.7/h5py/tests
creating build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/__init__.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_attrs.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_attrs_data.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_base.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_dataset.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_datatype.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_dimension_scales.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_file.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_file_image.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_group.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_h5.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_h5d_direct_chunk_write.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_h5f.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_h5p.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_h5t.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_objects.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_selections.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
copying h5py/tests/old/test_slicing.py -> build/lib.linux-ppc64le-3.7/h5py/tests/old
creating build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/__init__.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_attribute_create.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_dataset_getitem.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_dataset_swmr.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_datatype.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_deprecation.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_dims_dimensionproxy.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_file.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_filters.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
copying h5py/tests/hl/test_threads.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl
creating build/lib.linux-ppc64le-3.7/h5py/tests/hl/test_vds
copying h5py/tests/hl/test_vds/__init__.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl/test_vds
copying h5py/tests/hl/test_vds/test_highlevel_vds.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl/test_vds
copying h5py/tests/hl/test_vds/test_lowlevel_vds.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl/test_vds
copying h5py/tests/hl/test_vds/test_virtual_source.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl/test_vds
running build_ext
Autodetected HDF5 1.10.2
********************************************************************************
Summary of the h5py configuration
Path to HDF5: None
HDF5 Version: '1.10.2'
MPI Enabled: False
Rebuild Required: True
********************************************************************************
Executing api_gen rebuild of defs
Executing cythonize()
[ 1/22] Cythonizing /tmp/pip-install-bpmeop26/h5py/h5py/_conv.pyx
/tmp/pip-install-bpmeop26/h5py/.eggs/Cython-0.29.21-py3.7.egg/Cython/Compiler/Main.py:369: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: /tmp/pip-install-bpmeop26/h5py/h5py/_conv.pxd
tree = Parsing.p_module(s, pxd, full_module_name)
...
/home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
#warning "Using deprecated NumPy API, disable it with " \
^
In file included from /tmp/pip-install-bpmeop26/h5py/h5py/defs.c:654:0:
/tmp/pip-install-bpmeop26/h5py/h5py/api_compat.h:27:18: fatal error: hdf5.h: No such file or directory
#include "hdf5.h"
^
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
ERROR: Failed building wheel for h5py
Running setup.py clean for h5py
Failed to build h5py
DEPRECATION: Could not build wheels for h5py which do not use PEP 517. pip will fall back to legacy 'setup.py install' for these. pip 21.0 will remove support for this functionality. A possible replacement is to fix the wheel build issue reported above. You can find discussion regarding this at https://github.com/pypa/pip/issues/8368.
Installing collected packages: Pillow, h5py, torchmeta
Attempting uninstall: Pillow
Found existing installation: Pillow 7.1.2
Uninstalling Pillow-7.1.2:
Successfully uninstalled Pillow-7.1.2
Attempting uninstall: h5py
Found existing installation: h5py 2.8.0
Uninstalling h5py-2.8.0:
Successfully uninstalled h5py-2.8.0
Running setup.py install for h5py ... error
ERROR: Command errored out with exit status 1:
command: /home/miranda9/.conda/envs/my_new_env/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-bpmeop26/h5py/setup.py'"'"'; __file__='"'"'/tmp/pip-install-bpmeop26/h5py/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-hlwpfooj/install-record.txt --single-version-externally-managed --compile --install-headers /home/miranda9/.conda/envs/my_new_env/include/python3.7m/h5py
...
copying h5py/tests/hl/test_vds/test_lowlevel_vds.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl/test_vds
copying h5py/tests/hl/test_vds/test_virtual_source.py -> build/lib.linux-ppc64le-3.7/h5py/tests/hl/test_vds
running build_ext
Autodetected HDF5 1.10.2
********************************************************************************
Summary of the h5py configuration
Path to HDF5: None
HDF5 Version: '1.10.2'
MPI Enabled: False
Rebuild Required: True
********************************************************************************
Executing cythonize()
[ 1/22] Cythonizing /tmp/pip-install-bpmeop26/h5py/h5py/_conv.pyx
/tmp/pip-install-bpmeop26/h5py/.eggs/Cython-0.29.21-py3.7.egg/Cython/Compiler/Main.py:369: FutureWarning: Cython directive 'language_level' not set, using 2 for now (Py2). This will change in a later release! File: /tmp/pip-install-bpmeop26/h5py/h5py/_conv.pxd
...
warning: h5py/api_types_hdf5.pxd:730:6: 'H5Z_ERROR_EDC' redeclared
warning: h5py/api_types_hdf5.pxd:731:6: 'H5Z_DISABLE_EDC' redeclared
warning: h5py/api_types_hdf5.pxd:732:6: 'H5Z_ENABLE_EDC' redeclared
warning: h5py/api_types_hdf5.pxd:733:6: 'H5Z_NO_EDC' redeclared
building 'h5py.defs' extension
creating build/temp.linux-ppc64le-3.7
creating build/temp.linux-ppc64le-3.7/tmp
creating build/temp.linux-ppc64le-3.7/tmp/pip-install-bpmeop26
creating build/temp.linux-ppc64le-3.7/tmp/pip-install-bpmeop26/h5py
creating build/temp.linux-ppc64le-3.7/tmp/pip-install-bpmeop26/h5py/h5py
gcc -pthread -B /home/miranda9/.conda/envs/my_new_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -DH5_USE_16_API -I./h5py -I/tmp/pip-install-bpmeop26/h5py/lzf -I/opt/local/include -I/usr/local/include -I/home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/numpy/core/include -I/home/miranda9/.conda/envs/my_new_env/include/python3.7m -c /tmp/pip-install-bpmeop26/h5py/h5py/defs.c -o build/temp.linux-ppc64le-3.7/tmp/pip-install-bpmeop26/h5py/h5py/defs.o
In file included from /home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/numpy/core/include/numpy/ndarraytypes.h:1830:0,
from /home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/numpy/core/include/numpy/ndarrayobject.h:12,
from /home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/numpy/core/include/numpy/arrayobject.h:4,
from /tmp/pip-install-bpmeop26/h5py/h5py/api_compat.h:26,
from /tmp/pip-install-bpmeop26/h5py/h5py/defs.c:654:
/home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:17:2: warning: #warning "Using deprecated NumPy API, disable it with " "#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp]
#warning "Using deprecated NumPy API, disable it with " \
^
In file included from /tmp/pip-install-bpmeop26/h5py/h5py/defs.c:654:0:
/tmp/pip-install-bpmeop26/h5py/h5py/api_compat.h:27:18: fatal error: hdf5.h: No such file or directory
#include "hdf5.h"
^
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
Rolling back uninstall of h5py
Moving to /home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/h5py
from /home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/~5py
Moving to /home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/h5py-2.8.0-py3.7.egg-info
from /home/miranda9/.conda/envs/my_new_env/lib/python3.7/site-packages/~5py-2.8.0-py3.7.egg-info
ERROR: Command errored out with exit status 1: /home/miranda9/.conda/envs/my_new_env/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-bpmeop26/h5py/setup.py'"'"'; __file__='"'"'/tmp/pip-install-bpmeop26/h5py/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-hlwpfooj/install-record.txt --single-version-externally-managed --compile --install-headers /home/miranda9/.conda/envs/my_new_env/include/python3.7m/h5py Check the logs for full command output.
anyone know how I can successfully install a working torchmeta version in a ppc64le (using wmcle 1.7.0)?
related:
gitissue for torchmeta: https://github.com/tristandeleu/pytorch-meta/issues/95
IBM gitissue for torchmeta support: https://github.com/IBM/powerai/issues/269
h5py gitissue for torchmeta: https://github.com/h5py/h5py/issues/1678
IBM h5py support for torchmeta: https://github.com/IBM/powerai/issues/270
Because there are not wheels for powerpc for h5py you are installing h5py from source (from the tarball). This requires both the Python and h5py development headers to be available, see https://docs.h5py.org/en/stable/build.html#source-installation.
Either install h5py from conda or install the required build dependencies.

locust is not installing on my windows 10 for load testing

I tried installing this pip but getting some error, I want this package module for load testing
This is the output i am getting:
Collecting locustio
Collecting geventhttpclient-wheels==1.3.1.dev2 (from locustio)
Using cached https://files.pythonhosted.org/packages/bc/7f/42f8b4ac6c7ddf606fa69769cef2229a159d4af45a294053198f52586095/geventhttpclient-wheels-1.3.1.dev2.tar.gz
Requirement already satisfied: six in c:\users\saurabh\appdata\local\programs\python\python38\lib\site-packages (from geventhttpclient-wheels==1.3.1.dev2->locustio) (1.14.0)
Requirement already satisfied: pycparser in c:\users\saurabh\appdata\local\programs\python\python38\lib\site-packages (from cffi>=1.12.2; platform_python_implementation == "CPython" and sys_platform == "win32"->gevent==20.4.0->locustio) (2.20)
Running setup.py install for geventhttpclient-wheels: started
Running setup.py install for geventhttpclient-wheels: finished with status 'error'
ERROR: Command errored out with exit status 1:
command: 'C:\Users\SauraBh\AppData\Local\Programs\Python\Python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\SauraBh\\AppData\\Local\\Temp\\pycharm-packaging\\geventhttpclient-wheels\\setup.py'"'"'; __file__='"'"'C:\\Users\\SauraBh\\AppData\\Local\\Temp\\pycharm-packaging\\geventhttpclient-wheels\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\SauraBh\AppData\Local\Temp\pip-record-ipuoqz4r\install-record.txt' --single-version-externally-managed --compile
cwd: C:\Users\SauraBh\AppData\Local\Temp\pycharm-packaging\geventhttpclient-wheels\
Complete output (45 lines):
C:\Users\SauraBh\AppData\Local\Programs\Python\Python38\lib\site-packages\setuptools\dist.py:471: UserWarning: Normalizing '1.3.1dev2' to '1.3.1.dev2'
warnings.warn(
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.8
creating build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\client.py -> build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\connectionpool.py -> build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\header.py -> build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\httplib.py -> build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\response.py -> build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\url.py -> build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\useragent.py -> build\lib.win-amd64-3.8\geventhttpclient
copying src\geventhttpclient\__init__.py -> build\lib.win-amd64-3.8\geventhttpclient
running egg_info
writing src\geventhttpclient_wheels.egg-info\PKG-INFO
writing dependency_links to src\geventhttpclient_wheels.egg-info\dependency_links.txt
writing requirements to src\geventhttpclient_wheels.egg-info\requires.txt
writing top-level names to src\geventhttpclient_wheels.egg-info\top_level.txt
reading manifest file 'src\geventhttpclient_wheels.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no previously-included files matching '__pycache__' found anywhere in distribution
warning: no previously-included files matching '*.py[co]' found anywhere in distribution
writing manifest file 'src\geventhttpclient_wheels.egg-info\SOURCES.txt'
creating build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\oncert.pem -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\server.crt -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\server.key -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_client.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_headers.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_httplib.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_keep_alive.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_network_failures.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_no_module_ssl.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_parser.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_ssl.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_url.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
copying src\geventhttpclient\tests\test_useragent.py -> build\lib.win-amd64-3.8\geventhttpclient\tests
warning: build_py: byte-compiling is disabled, skipping.
running build_ext
building 'geventhttpclient._parser' extension
error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\Users\SauraBh\AppData\Local\Programs\Python\Python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\SauraBh\\AppData\\Local\\Temp\\pycharm-packaging\\geventhttpclient-wheels\\setup.py'"'"'; __file__='"'"'C:\\Users\\SauraBh\\AppData\\Local\\Temp\\pycharm-packaging\\geventhttpclient-wheels\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\SauraBh\AppData\Local\Temp\pip-record-ipuoqz4r\install-record.txt' --single-version-externally-managed --compile Check the logs for full command output.
I have Microsoft Visual C++ 14.0.25 is installed in my system.
If someone knows any better tool/framework/package for testing api using python please help me. I want to check the registration api with many users at a time.
If Dmitri's suggestion doesnt help, you might want to try this:
pip install -U setuptools
And update to latest locust:
pip install -U locust
(Edit: locust package name is now ”locust”, not ”locustio”)
What you need is not Visual Studio, you need Visual C++ build tools
You can install it using using Visual Studio Installer, you just need to tick the relevant box under the C++ components:
You might also be interested in How to Run Locust with Different Users article

Mysqldb is not installing in flask Application am using pycharm

I am new in flask python development,I tried to use the following command below in Pycharm to enable Mysql usage in my Application, but it's not working :
install Flask-mysqldb
It throws the following information after i enter the command, i dont know if i am missing something , but i already have mysql installed on my computer and i created all my databases but there's no successful installation message anywhere:
Collecting Flask-mysqldb
Collecting mysqlclient (from Flask-mysqldb)
Using cached mysqlclient-1.3.12.tar.gz
Requirement already satisfied: Flask>=0.10 in c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\lib\site-packages (from Flask-mysqldb)
Requirement already satisfied: itsdangerous>=0.21 in c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\lib\site-packages (from Flask>=0.10->Flask-mysqldb)
Requirement already satisfied: click>=2.0 in c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\lib\site-packages (from Flask>=0.10->Flask-mysqldb)
Requirement already satisfied: Werkzeug>=0.7 in c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\lib\site-packages (from Flask>=0.10->Flask-mysqldb)
Requirement already satisfied: Jinja2>=2.4 in c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\lib\site-packages (from Flask>=0.10->Flask-mysqldb)
Requirement already satisfied: MarkupSafe>=0.23 in c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\lib\site-packages (from Jinja2>=2.4->Flask>=0.10->Flask
-mysqldb)
Building wheels for collected packages: mysqlclient
Running setup.py bdist_wheel for mysqlclient ... error
Complete output from command c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\scripts\python.exe -u -c "import setuptools, tokenize;__file__='c:\\users\\
huzy_k~1\\appdata\\local\\temp\\pip-build-8jxhwx\\mysqlclient\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.clos
e();exec(compile(code, __file__, 'exec'))" bdist_wheel -d c:\users\huzy_k~1\appdata\local\temp\tmpefdo3cpip-wheel- --python-tag cp27:
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-2.7
copying _mysql_exceptions.py -> build\lib.win-amd64-2.7
creating build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\__init__.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\compat.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\connections.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\converters.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\cursors.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\release.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\times.py -> build\lib.win-amd64-2.7\MySQLdb
creating build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\__init__.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\CLIENT.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\CR.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\ER.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\FIELD_TYPE.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\FLAG.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\REFRESH.py -> build\lib.win-amd64-2.7\MySQLdb\constants
running build_ext
building '_mysql' extension
creating build\temp.win-amd64-2.7
creating build\temp.win-amd64-2.7\Release
C:\Users\Huzy_Kamz\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\VC\Bin\amd64\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -Dversion_info=
(1,3,12,'final',0) -D__version__=1.3.12 "-IC:\Program Files (x86)\MySQL\MySQL Connector C 6.1\include" -IC:\Python27\include -Ic:\users\huzy_kamz\pycharmprojec
ts\myfirstflask\venv\PC /Tc_mysql.c /Fobuild\temp.win-amd64-2.7\Release\_mysql.obj /Zl
_mysql.c
_mysql.c(29) : fatal error C1083: Cannot open include file: 'mysql.h': No such file or directory
error: command 'C:\\Users\\Huzy_Kamz\\AppData\\Local\\Programs\\Common\\Microsoft\\Visual C++ for Python\\9.0\\VC\\Bin\\amd64\\cl.exe' failed with exit statu
s 2
----------------------------------------
Failed building wheel for mysqlclient
Running setup.py clean for mysqlclient
Failed to build mysqlclient
Installing collected packages: mysqlclient, Flask-mysqldb
Running setup.py install for mysqlclient ... error
Complete output from command c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\scripts\python.exe -u -c "import setuptools, tokenize;__file__='c:\\users
\\huzy_k~1\\appdata\\local\\temp\\pip-build-8jxhwx\\mysqlclient\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.cl
ose();exec(compile(code, __file__, 'exec'))" install --record c:\users\huzy_k~1\appdata\local\temp\pip-4xug6v-record\install-record.txt --single-version-extern
ally-managed --compile --install-headers c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\include\site\python2.7\mysqlclient:
running install
running build
running build_py
creating build
creating build\lib.win-amd64-2.7
copying _mysql_exceptions.py -> build\lib.win-amd64-2.7
creating build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\__init__.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\compat.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\connections.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\converters.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\cursors.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\release.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\times.py -> build\lib.win-amd64-2.7\MySQLdb
creating build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\__init__.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\CLIENT.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\CR.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\ER.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\FIELD_TYPE.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\FLAG.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\REFRESH.py -> build\lib.win-amd64-2.7\MySQLdb\constants
running build_ext
building '_mysql' extension
creating build\temp.win-amd64-2.7
creating build\temp.win-amd64-2.7\Release
C:\Users\Huzy_Kamz\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\VC\Bin\amd64\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -Dversion_inf
o=(1,3,12,'final',0) -D__version__=1.3.12 "-IC:\Program Files (x86)\MySQL\MySQL Connector C 6.1\include" -IC:\Python27\include -Ic:\users\huzy_kamz\pycharmproj
ects\myfirstflask\venv\PC /Tc_mysql.c /Fobuild\temp.win-amd64-2.7\Release\_mysql.obj /Zl
_mysql.c
_mysql.c(29) : fatal error C1083: Cannot open include file: 'mysql.h': No such file or directory
error: command 'C:\\Users\\Huzy_Kamz\\AppData\\Local\\Programs\\Common\\Microsoft\\Visual C++ for Python\\9.0\\VC\\Bin\\amd64\\cl.exe' failed with exit sta
tus 2
----------------------------------------
Command "c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\scripts\python.exe -u -c "import setuptools, tokenize;__file__='c:\\users\\huzy_k~1\\appdata\\loc
al\\temp\\pip-build-8jxhwx\\mysqlclient\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code,
__file__, 'exec'))" install --record c:\users\huzy_k~1\appdata\local\temp\pip-4xug6v-record\install-record.txt --single-version-externally-managed --compile -
-install-headers c:\users\huzy_kamz\pycharmprojects\myfirstflask\venv\include\site\python2.7\mysqlclient" failed with error code 1 in c:\users\huzy_k~1\appdata
\local\temp\pip-build-8jxhwx\mysqlclient\
From where do you run this:
install Flask-mysqldb
?
The nice tool must obtain all needed things by default. If no, try another tool. Try use pip from Miniconda with PyCharm.
Install Miniconda with default options https://conda.io/miniconda.html Create the new PyCharm project (for example 'myproject') and select conda as the environment manager. Just print new relevant paths by your hands, so project folder and environment folder will be created automaticaly, see
Then open Anaconda Prompt from Windows Start Menu.
See
Then run commands:
activate myproject
pip install flask-mysqldb
See
Also, you can install all packages which are needed for your project.
If you do not want use conda instead virtualenv, select virtualenv, but virtualenv from Miniconda, as far as Miniconda is more tested and work out of the box without such errors. You can use your usual python in your old project, and select Miniconda for new project, it is not dangerous. See example of select virtualenv from Miniconda:
In new project open console by hit Ctrl+F12 and run:
pip install flask-mysqldb
Result is next:
Collecting flask-mysqldb
Collecting Flask>=0.10 (from flask-mysqldb)
Using cached Flask-0.12.2-py2.py3-none-any.whl
Collecting mysqlclient (from flask-mysqldb)
Using cached mysqlclient-1.3.12-cp36-cp36m-win_amd64.whl
Collecting Werkzeug>=0.7 (from Flask>=0.10->flask-mysqldb)
Using cached Werkzeug-0.14.1-py2.py3-none-any.whl
Collecting Jinja2>=2.4 (from Flask>=0.10->flask-mysqldb)
Using cached Jinja2-2.10-py2.py3-none-any.whl
Collecting itsdangerous>=0.21 (from Flask>=0.10->flask-mysqldb)
Collecting click>=2.0 (from Flask>=0.10->flask-mysqldb)
Using cached click-6.7-py2.py3-none-any.whl
Collecting MarkupSafe>=0.23 (from Jinja2>=2.4->Flask>=0.10->flask-mysqldb)
Installing collected packages: Werkzeug, MarkupSafe, Jinja2, itsdangerous, click, Flask, mysqlclient, flask-mysqldb
Successfully installed Flask-0.12.2 Jinja2-2.10 MarkupSafe-1.0 Werkzeug-0.14.1 click-6.7 flask-mysqldb-0.2.0 itsdangerous-0.24 mysqlclient-1.3.12

pip Install error for mysql-python not working

I am trying to use the pip install mysql-python command and I get the error below. I have no idea what this means someone please help. I have already updated my verison of pip and setuptools and wheels so I am at a loss. I get a big error message but only have the first half presented below.
C:\Users\Alex\Desktop\Cornell Stuff\Computer Programs\WinPython-64bit-
3.4.3.3\python-3.4.3.amd64>pip install mysql-python
Collecting mysql-python
Downloading MySQL-python-1.2.5.zip (108kB)
100% |################################| 112kB 179kB/s
Building wheels for collected packages: mysql-python
Running setup.py bdist_wheel for mysql-python ... error
Complete output from command "C:\Users\Alex\Desktop\Cornell Stuff\Computer
Programs\WinPython-64bit-3.4.3.3\python-3.4.3.amd64\python.exe" -u -c
"import setuptools,
tokenize;__file__='C:\\Users\\Alex\\AppData\\Local\\Temp\\pip-build-
1kxb8j7_\\mysql-python\\setup.py';f=getattr(tokenize, 'open', open)
(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code,
__file__, 'exec'))" bdist_wheel -d
C:\Users\Alex\AppData\Local\Temp\tmpzz01n6ylpip-wheel- --python-tag cp34:
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-3.4
copying _mysql_exceptions.py -> build\lib.win-amd64-3.4
creating build\lib.win-amd64-3.4\MySQLdb
copying MySQLdb\__init__.py -> build\lib.win-amd64-3.4\MySQLdb
copying MySQLdb\converters.py -> build\lib.win-amd64-3.4\MySQLdb
copying MySQLdb\connections.py -> build\lib.win-amd64-3.4\MySQLdb
copying MySQLdb\cursors.py -> build\lib.win-amd64-3.4\MySQLdb
copying MySQLdb\release.py -> build\lib.win-amd64-3.4\MySQLdb
copying MySQLdb\times.py -> build\lib.win-amd64-3.4\MySQLdb
creating build\lib.win-amd64-3.4\MySQLdb\constants
copying MySQLdb\constants\__init__.py -> build\lib.win-amd64-
3.4\MySQLdb\constants
copying MySQLdb\constants\CR.py -> build\lib.win-amd64-
3.4\MySQLdb\constants
copying MySQLdb\constants\FIELD_TYPE.py -> build\lib.win-amd64-
3.4\MySQLdb\constants
copying MySQLdb\constants\ER.py -> build\lib.win-amd64-
3.4\MySQLdb\constants
copying MySQLdb\constants\FLAG.py -> build\lib.win-amd64-
3.4\MySQLdb\constants
copying MySQLdb\constants\REFRESH.py -> build\lib.win-amd64-
3.4\MySQLdb\constants
copying MySQLdb\constants\CLIENT.py -> build\lib.win-amd64-
3.4\MySQLdb\constants
running build_ext
building '_mysql' extension
creating build\temp.win-amd64-3.4
creating build\temp.win-amd64-3.4\Release
C:\Users\Alex\Desktop\Cornell Stuff\Computer Programs\WinPython-64bit-
3.4.3.3\python-3.4.3.amd64\..\tools\mingw32\bin\gcc.exe -mdll -O -DMS_WIN64
-Wall -Dversion_info=(1,2,5,'final',1) -D__version__=1.2.5 "-IC:\Program
Files (x86)\MySQL\MySQL Connector C 6.0.2\include" "-
IC:\Users\Alex\Desktop\Cornell Stuff\Computer Programs\WinPython-64bit-
3.4.3.3\python-3.4.3.amd64\include" "-IC:\Users\Alex\Desktop\Cornell
Stuff\Computer Programs\WinPython-64bit-3.4.3.3\python-3.4.3.amd64\include"
-c _mysql.c -o build\temp.win-amd64-3.4\Release\_mysql.o /Zl
gcc: error: /Zl: No such file or directory
error: command 'C:\\Users\\Alex\\Desktop\\Cornell Stuff\\Computer
Programs\\WinPython-64bit-3.4.3.3\\python-
3.4.3.amd64\\..\\tools\\mingw32\\bin\\gcc.exe' failed with exit status 1
----------------------------------------
Failed building wheel for mysql-python
Running setup.py clean for mysql-python
Failed to build mysql-python
it's written there that mysql-python may not be python-3 compatible : https://www.lfd.uci.edu/~gohlke/pythonlibs/#mysql-python
you may rather try, for example: "pip install mysql-connector-python"

IMDBPy installing mysqlclient fails - Python 2.7 Windows

I'm a former developer, but haven't done much with Python to date. I'm trying to get the full IMDB database into a MySQL server before the text files go poof.
I now know IMDBPy requires Python 2.7 (thanks David!) so I am on a clean machine with Py 2.7 installed. My understanding is that I need several packages installed before I can run the imdbpy2sql script successfully.
These are:
Python 2.7
MySQL (using the latest version of community server 5.7.2)
SQL Object
mysqlclient (requires VC++ compliler for Python
2.7)
I have everything installed up to the mysqlclient. When I attempt to install it, it fails with a message that seems to indicate it cannot find the \include folder for MySQL.
C:\Windows\system32>pip install -U SQLObject
Collecting SQLObject
Downloading SQLObject-3.4.0-py2.py3-none-any.whl (1.7MB)
100% |################################| 1.8MB 652kB/s
Collecting PyDispatcher>=2.0.4 (from SQLObject)
Downloading PyDispatcher-2.0.5.tar.gz
Collecting FormEncode!=1.3.0,>=1.1.1 (from SQLObject)
Downloading FormEncode-1.3.1.tar.gz (197kB)
100% |################################| 204kB 3.3MB/s
Installing collected packages: PyDispatcher, FormEncode, SQLObject
Running setup.py install for PyDispatcher ... done
Running setup.py install for FormEncode ... done
Successfully installed FormEncode-1.3.1 PyDispatcher-2.0.5 SQLObject-3.4.0
C:\Windows\system32>pip install mysqlclient
Collecting mysqlclient
Downloading mysqlclient-1.3.12.tar.gz (89kB)
100% |################################| 92kB 837kB/s
Installing collected packages: mysqlclient
Running setup.py install for mysqlclient ... error
Complete output from command c:\python27\python.exe -u -c "import setuptools, tokenize;__file__='c:\\users\\michael\\appdata\\local\\temp\\pip-build-jgsnac\\mysqlclient\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record c:\users\michael\appdata\local\temp\pip-uwgilx-record\install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
creating build
creating build\lib.win-amd64-2.7
copying _mysql_exceptions.py -> build\lib.win-amd64-2.7
creating build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\__init__.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\compat.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\connections.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\converters.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\cursors.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\release.py -> build\lib.win-amd64-2.7\MySQLdb
copying MySQLdb\times.py -> build\lib.win-amd64-2.7\MySQLdb
creating build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\__init__.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\CLIENT.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\CR.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\ER.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\FIELD_TYPE.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\FLAG.py -> build\lib.win-amd64-2.7\MySQLdb\constants
copying MySQLdb\constants\REFRESH.py -> build\lib.win-amd64-2.7\MySQLdb\constants
running build_ext
building '_mysql' extension
creating build\temp.win-amd64-2.7
creating build\temp.win-amd64-2.7\Release
C:\Users\Michael\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\VC\Bin\amd64\cl.exe /c /nologo /Ox /MD /W3 /GS- /DNDEBUG -Dversion_info=(1,3,12,'final',0) -D__version__=1.3.12 "-IC:\Program Files (x86)\MySQL\MySQL Connector C 6.1\include" -Ic:\python27\include -Ic:\python27\PC /Tc_mysql.c /Fobuild\temp.win-amd64-2.7\Release\_mysql.obj /Zl
_mysql.c
_mysql.c(29) : fatal error C1083: Cannot open include file: 'mysql.h': No such file or directory
error: command 'C:\\Users\\Michael\\AppData\\Local\\Programs\\Common\\Microsoft\\Visual C++ for Python\\9.0\\VC\\Bin\\amd64\\cl.exe' failed with exit status 2
----------------------------------------
Command "c:\python27\python.exe -u -c "import setuptools, tokenize;__file__='c:\\users\\michael\\appdata\\local\\temp\\pip-build-jgsnac\\mysqlclient\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record c:\users\michael\appdata\local\temp\pip-uwgilx-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in c:\users\michael\appdata\local\temp\pip-build-jgsnac\mysqlclient\
I have confirmed the include folder is there as well as the mysql.h file it is looking for (the default installation location was "c:\Program Files\MySQL\MySQL Server 5.7\include"). I didn't have a problem installing mysqlclient when I was using a newer version of Python (3). So I'm assuming there's some disconnect between the 2.7 version and newer versions of MySQL. Maybe a config file that needs to be updated? Any help would be appreciated.
Install driver first and then try if it works.
Download & Install Python MySQL Connector driver from following link.
https://dev.mysql.com/downloads/connector/c/6.0.html#downloads
pip install MySQL-Python
Refer:
https://github.com/PyMySQL/mysqlclient-python/issues/142

Categories