TrueBlocks / Trueblocks Core
Programming Languages
Labels
Projects that are alternatives of or similar to Trueblocks Core
TrueBlocks Core
TrueBlocks allows you to build local-first, fully-decentralized applications using data directly from an Ethereum node. It does this through two mechanisms:
- A lightning-fast index of every appearance of every addresses on the chain, and
- A binary cache of only the data your application extracts.
Local-first means your application is private by default, the client-side cache means your application is fast, and extraction-on-demand means your application will remain minimal.
Prerequisites
Before building TrueBlocks, you need to make sure you have git
, cmake
, clang-format
, and go
available.
Follow these instructions for installing golang
on your system.
Complete these commands to install git
, cmake
, and clang-format
:
On Linux:
sudo apt install build-essential git cmake python python-dev libcurl3-dev clang-format jq
On Mac:
brew install cmake
brew install git
brew install clang-format
brew install jq
Building TrueBlocks
Currently, you must build TrueBlocks from source:
git clone [email protected]:TrueBlocks/trueblocks-core.git
cd trueblocks-core
mkdir build && cd build
cmake ../src
make
This will create a series of executables in the ./bin
folder at the top of the repo. The following instructions assume you've added this folder to your $PATH
.
Does TrueBlocks Work on Windows?
Testing Installation
After building TrueBlocks, you may test your configuration with this command:
chifra --version
For a complete list of available commands, run this command:
chifra --help
Next, let's see if you can get a block from your Ethereum node. Enter this command:
chifra blocks 1000
This should return valid JSON data for block 1,000 (type getBlock --help
for more options on this tool.) If you get an error, such as this:
Warning: The Ethereum RPC: 'http://localhost:8545' was not found. Quitting...
You need to edit the file ~/.quickBlocks/quickBlocks.toml
to provide the URL of an available Ethereum RPC provider. Enter this text (adding the settings
sections if it's not present):
[settings]
rpcProvider="<url-to-your-rpc-provider>
Once you get chifra blocks
to return JSON data, you are ready to test your installtion. While optional, one of the tools (ethslurp
) requires an Etherscan key. Get an EtherScan API key now, then run:
make tests
Using TrueBlocks
The chifra
tool is the basis for everything related to TrueBlocks. (chifra
is derived from the Arabic word for chipher
.) It helps you decipher chain data.
Contributing to TrueBlocks
Please see information about our work flow before proceeding.
- Fork this repository into your own repo.
- Create a branch:
git checkout -b <branch_name>
. - Make changes and commit them:
git commit -m '<commit_message>'
- Push to the original branch:
git push origin TrueBlocks/trueblocks-core
- Create the pull request.
Contributors
Thanks to the following people who have contributed to this project:
Contact
If you have specific requests, contact us here [email protected].
License
This project licensed under the Apache License Version 2.0.