Getting Started

Supported Platforms

We currently support Linux(x86) and Mac(AppleSilicon).
You may be able to use Dojo in Windows using WSL, but we are not actively developing for it.

We aim to always support the latest version of Python. Currently we support 3.10+.


Licensing

You will need a license key to run Dojo. To get started, you can request a trial license.

The trial license is only valid for a couple of weeks on a single machine, but hopefully it's enough to get you excited about Dojo.


Prerequisites

There's a few more things you need to set up for Dojo. If you've done some coding in web3 before, chances are you're good to go already!

  1. RPC Node provider: setup an account with a provider, such as Infura, or use your own archive node. You'll need the RPC_URL it provides. e.g. https://mainnet.infura.io/v3/ac8ee<...>961
  2. A local ethereum development environment: we recently switched from hardhat to anvil. Check out the installation guide here.

Setup

Setting up Dojo shouldn't take more than 5 minutes:

1. Install dojo

Dojo is provided as a Python package on PyPi. To install, simply run

Terminal
pip install dojo-compass

2. Install Anvil

Dojo requires Anvil as EVM. It's what's going to process the raw transactions on your local machine.
Installing it is simple. Just follow the instructions here.

3. Setup configuration

Create a .env file in your main directory, or export the environment variables:

.env
RPC_URL=<YOUR URL>
CHAIN=<chain> # for now only supports "ethereum"
LICENSE_KEY=<YOUR LICENSE KEY>

For RPC_URL, you'll need to provide an etherum archive node address. We recommend to setup an account with a provider, such as Infura and specify the RPC_URL it provides.
The archive node is only used to read the pool state at simulation start, but if you prefer, you can also setup your own node, of course.

4. Verify install

If everything is set up correctly, the following command should throw no errors.

Terminal
python -c "from dojo.environments import UniV3Env"

Congratulations! You've got everything working as expected.