Build From Source Using pip¶
This section describes how to deploy MindsDB from the source code. It is the preferred way to use MindsDB if you want to contribute to our code or debug MindsDB.
Python 3.9
Currently, some of our dependencies have issues with the latest versions of Python 3.9.x. For now, our suggestion is to use Python 3.7.x, or 3.8.x versions.
Suggestions
Install MindsDB in a virtual environment when using pip to avoid dependency issues. Make sure your Python>=3.7 and pip>=19.3.
Installation¶
We recommend installing MindsDB inside a virtual environment to avoid dependency issues.
-
Clone the repository:
git clone git@github.com:mindsdb/mindsdb.git
-
Create new virtual environment called mindsdb-venv:
python -m venv mindsdb-venv
And, activate it:
source mindsdb-venv/bin/activate
-
Install MindsDB prerequisites:
cd mindsdb && pip install -r requirements.txt
-
Install MindsDB:
python setup.py develop
-
To verify everything works, start the MindsDB server:
python -m mindsdb
-
Now you should be able to access:
http://127.0.0.1:47334/api
http://127.0.0.1:47334/
mysql -h 127.0.0.1 --port 3306 -u mindsdb -p
Troubleshooting¶
Common Issues¶
No module named mindsdb
If you get this error, make sure that your virtual environment is activated.
ImportError: No module named {dependency name}
This type of error can occur if you skipped the 3rd step. Make sure that you install all of the MindsDB requirements.
This site can’t be reached. 127.0.0.1 refused to connect.
Please check the MindsDB server console in case the server is still in the starting
phase. If the server has started and there is an error displayed, please report it on our GitHub
Still Having problems?¶
Don't worry! Try to replicate the issue using the official docker setup, and please create an issue on our Github repository as detailed as possible.
We'll review it and give you a response within a few hours.