Use python to build a blockchain system.
Run the command
pip install -r requirements.txt
python node.py
After installing packages, open the browser with the URL localhost:5000
(default)
For example, if we want to run 2 nodes in the network. Open two terminals and input the following commands for the corresponding terminal. Node 1 (This node runs in port 5000)
python node.py
Node 2 (This node runs in port 5001, you can change the port by yourself)
python node.py -p 5001
There are two node.py
files. One is OLD_node.py
, which is the legacy version of node.py
and it only enable users to interact with the blockchain locally in the terminal. The new node.py
achieves APIs server, and the Web UI is allowed.
In the project, package pycrypto
is needed. When installing it, install pycryptodome
rather than pycrypto
. The usages is the same.
pip install pycryptodome
5 handsome students
https://www.udemy.com/course/learn-python-by-building-a-blockchain-cryptocurrency/?couponCode=D_0323