OctoBot developer installation
Setting up the recommended OctoBot development environment
This page is referring to OctoBot in versions superior to 0.4.0.

Install OctoBot requirements

Download and install:
  • IDE: PyCharm
  • SCM: Git
  • We also use GitKraken to easily manage OctoBot's multiple repos, this is just a quality of life improvement and is not necessary.
  • Programming language: Python 3.8

Additional dependencies for Windows

Additional dependencies for Mac

OctoBot repositories

Cloning OctoBot repositories with git

  • open a terminal in your project folder and execute the following commands to download the repos
git clone https://github.com/Drakkar-Software/OctoBot.git --branch dev
git clone https://github.com/Drakkar-Software/OctoBot-Tentacles.git --branch dev
git clone https://github.com/Drakkar-Software/OctoBot-Trading.git
git clone https://github.com/Drakkar-Software/OctoBot-Evaluators.git
git clone https://github.com/Drakkar-Software/OctoBot-Services.git
git clone https://github.com/Drakkar-Software/OctoBot-Backtesting.git
git clone https://github.com/Drakkar-Software/OctoBot-Tentacles-Manager.git
git clone https://github.com/Drakkar-Software/OctoBot-Commons.git
git clone https://github.com/Drakkar-Software/Async-Channel.git
git clone https://github.com/Drakkar-Software/trading-backend.git
  • now you should have all the OctoBot repos in one folder

Manage repositories with GitKraken

  • open each folder in GitKraken
  • add your project directory (the folder where all repo folders are located)
  • now add each folder
  • Now you have all repositories open as tabs and you can switch between git repositories and branches

Switch to experimental branches

  • You can explore and switch to different branches by double-clicking on the branch name for each repository, or right click "reset to this commit".

Setting up the IDE

We recommend using PyCharm to navigate through the OctoBot projects. This IDE will allow you to open and navigate through the multiple OctoBot repositories and make your OctoBot run setup use the code directly from the cloned repos using the project dependencies.
  • Open Pycharm and open the folder where all the OctoBot repositories are.

Add Python interpreter

  1. 1.
    click on "<No interpreter>"
  2. 2.
    then click on "Add Interpreter..."
  1. 1.
    select "Virtualenv Environment"
  2. 2.
    select the location of your venv. This should be your OctoBot project folder with "/venv" at the end
  3. 3.
    select your base interpreter and make sure its python 3.8 or 38

Add OctoBot modules

This will allow your PyCharm python runner to use your OctoBot repositories as source code directly. Thanks to this you will be able to edit any file in any repo and it will be taken into account in your other PyCharm run profiles runners from other open OctoBot repo. This is useful when running tests. If you skip this, you will need to install every OctoBot module with pip and won't be able to edit their code.

Add OctoBot modules with PyCharm Pro

  • In File/Settings/Project/Python Dependencies: For each repository: check its required OctoBot repository dependency.

Add OctoBot modules with PyCharm Community

Go to File -> Settings and add your OctoBot module folders as a project source

Install Octobot dependencies

  • For each OctoBot's repository: install missing dependencies in requirements.txt and dev_requirements.txt
  • To install these requirements on your pycharm virtual environement, you can either:
    • Manually go through each file listed in the commands bellow and install its requirements using the PyCharm requirements plugin
    • In a new terminal, activate your the virtual environement create by PyCharm (venv directory) and then run the following commands
pip install -r OctoBot/requirements.txt
pip install -r OctoBot-Backtesting/requirements.txt
pip install -r OctoBot-Commons/requirements.txt
pip install -r OctoBot-evaluators/requirements.txt
pip install -r OctoBot-Services/requirements.txt
pip install -r OctoBot-Tentacles-Manager/requirements.txt
pip install -r OctoBot-Trading/requirements.txt
pip install -r Async-Channel/requirements.txt
pip install -r trading-backend/requirements.txt
pip install -r OctoBot-Backtesting/dev_requirements.txt
pip install -r OctoBot-Commons/dev_requirements.txt
pip install -r OctoBot-evaluators/dev_requirements.txt
pip install -r OctoBot-Services/dev_requirements.txt
pip install -r OctoBot-Tentacles-Manager/dev_requirements.txt
pip install -r OctoBot-Trading/dev_requirements.txt
pip install -r OctoBot-Trading/dev_requirements.txt
pip install -r trading-backend/dev_requirements.txt
Through the requirements you have also installed OctoBot packages related to the previously downloaded repositories. You must uninstall them or your python runner will use them instead of your local code version.
  • remove OctoBot pip packages to use the packages from your project directory
pip uninstall -y OctoBot-Backtesting OctoBot-Trading Async-Channel OctoBot-Evaluators OctoBot-Commons OctoBot-Tentacles-Manager OctoBot-Services trading-backend

Create starting scripts in pyCharm

Create PyCharm run configurations using the previously created virtual env (with all the dependencies installed) for each way you want to start python commands (running OctoBot, running tests, etc).

Introduction to OctoBot scripts

Here we explain how to setup and run two scripts for OctoBot, but there are way more you can set up by yourself, explore the rest of the docs to find out more commands

OctoBot starting script

this script will run OctoBot and apply all changes made to all repositories except the OctoBot-Tentacles folder (see install OctoBot-Tentacles and run OctoBot script)
  • click on Add Configuration
now add a new python script

Start OctoBot in pyCharm

  • You can now run and debug the whole OctoBot project and its repositories by clicking on the play button, or on the debugging button to run the debugger

Install OctoBot-Tentacles and run OctoBot script

this script will install the OctoBot-Tentacles folder and run Octobot with all your changes applied from all repositories.

Create the following three scripts:

  • **Script to create an installable OctoBot-Tentacles package **
  • Script to install OctoBot-Tentacles package
  • Script to zip, install and run in one go
Export as PDF
Copy link
On this page
Install OctoBot requirements
Additional dependencies for Windows
Additional dependencies for Mac
OctoBot repositories
Cloning OctoBot repositories with git
Manage repositories with GitKraken
Switch to experimental branches
Setting up the IDE
Add Python interpreter
Add OctoBot modules
Add OctoBot modules with PyCharm Pro
Add OctoBot modules with PyCharm Community
Install Octobot dependencies
Create starting scripts in pyCharm
Introduction to OctoBot scripts
OctoBot starting script
Start OctoBot in pyCharm
Install OctoBot-Tentacles and run OctoBot script