Other names may be trademarks of their respective owners. Please assume I know next to nothing about Linux. Get Pip Note: As of Python 2. I have been trying the conda install to Anaconda 2. Done Building dependency tree Reading state information. Pip makes installing libraries for your Python environment a breeze, and when you start developing your own packages it provides a way for you to declare dependencies so those dependent packages will get installed automatically as well. I've install virtualenv and after activation then I run pip install mysql-connector-python, but when I run my app I get an error: ImportError: No module named mysql.
I had the same problem too. Done The following packages were automatically installed and are no longer required: linux-headers-4. If you instead try and install the 32-bit version, I think you get the unsupported wheel error in comments below. Yet both of these failed : Python 2. I was able to run my app inside of my venv by installing the python connector outside of virtualenv and then manually copying what was installed in the site-packages folder into my virtual environments site-packages folder. Another way is the answer of bob90937. Installing the World Database All the examples in this tutorial will query the world sample database.
And what is this virtualenv thing people keep telling me I should use? System: Fedora 20 Django Python 3. If you navigate to the location listed, there might not be a file there to edit. If you have a project with lots of package requirements, it might have come with or you might have written a often called requirements. There are more details on this at. I can log, create a python virtual environment, install modules, and manually invoke python. Before doing that, I also used the windows repair installation tool in two different python versions I have installed.
How to install mysql-connector-python without pip git clone git github. If a system package expects the system provided virtualenv and an incompatible version is installed with --user that package may have problems within that user account. Has anyone else had trouble doing this? However, once you moved to the production environment you should definitely consider using the C extension. For packaging types that have separate distribution files, install either one or both packages. Hobbyist programmer here… I got Python installed on my account.
My env details - Python 2. The easiest way to install pip is to download the script, save it locally, then run it using Python. This is no solution however as it defeats the purpose of virtualenv. Follow these steps if you are on Windows. I tested this connector with the Django tutorial app and got.
That explains I bet what is happening is that the paths for the python libraries are not set correctly. Most of the examples in this tutorial uses pure Python implementation. The , but the key thing to know is that you need to point it to the python. Using pip install --user is less hazardous but can still cause trouble within the particular user account. However, mysql -u root -p does start mysql successfully inside or outside the virtual environment? Now try to import the module again.
I found this thread while looking to solve a similar problem. If you do that, you can skip this step. Of course you also get regular PowerShell tab completion for these cmdlets and aliases. I just had the same problem and none of the solutions below worked. Well, silly, you forgot to import the virtualenvwrapper module! Note: Previous versions of this guide included a step to download and install Distribute. Choose an installer appropriate for the version of Python installed on your system. You can get the Python 2.
It's good to use a platform that you're comfortable with. Edit: I missed that you were using it inside a virtual environment! To install within your user account with pip if you have pip 1. This wrapper makes creating new virtual environments and switching between them really straightforward. . To use site packages inside a virtualenv, you have to pass --system-site-packages to virtualenv, e.
There are cases where an app made on a different platform doesn't work on others or needs specific tweaks, so getting it cross-tested should be in your worklist. Just make sure they are properly formatted to run in multiple platforms. Generally use your system package manager if it provides a package. Does that mean external to github? This way, things such as debugging and coding are easier. I see you mentioned externally hosted projects. I am here to do something to add.