The project involved the implementation of a blockchain model using an object-oriented approach. The model was equipped with several functionalities including the ability to view the chain, mine blocks using a simple proof of work algorithm, evaluate validity, and ensure traceability in case of any unauthorized modifications.
Checkout the web application here.
NOTE: There could be some issues when viewing the current blockchain after mining/modifying a block. This is due to the browser cache. You can use the "Reset blockchain" button or alternatively open the app in incognito mode.
├── LICENSE
├── Makefile <- Makefile with commands like `make create_environment` or `make requirements`
├── README.md <- The top-level README for developers using this project
├── readme-assets <- Contains images to be used in README.md
├── static
│ └── css <- Contains stylesheet for styling webpage
│
├── templates <- Contains html templates to be rendered
├── requirements.txt <- The requirements file for reproducing the project environment
├── test_environment.py <- Script to test virtual environment
├── blockchain.py <- Contains blockchain class
├── Procfile <- Deployment specific requirement (for Heroku)
└── app.py <- Contains code for application
Before you begin, ensure you have met the following requirements:
- You have a
Linux/Mac/Windows
machine. - You have installed a
python
distribution.conda
is preferred. - You have installed
pip
. - You have installed
make
.
- Clone the repo
git clone https://github.com/himalayasharma/elementary-blockchain.git
- Traverse into project directory.
- Create virtual environment.
make create_environment
- Activate virtual environment.
- Download and install all required packages.
make requirements
- Start application (in debug mode).
make app
Screenshot 1: A brief introduction of what a blockchain is.
Screenshot 2: Functionality to mine block.
Screenshot 3: Checks to ensure validity and view current blockchain.
Screenshot 4: Functionality to modify existing blockchain along with an option to reset it completely.
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated. If you have a suggestion that would make this better, please fork the repo and create a pull request. Don't forget to give the project a star! Thanks again!
- Fork this repository.
- Create a branch:
git checkout -b <branch_name>
. - Make your changes and commit them:
git commit -m '<commit_message>'
- Push to the original branch:
git push origin <project_name>/<location>
- Create the pull request.
Alternatively see the GitHub documentation on creating a pull request.
Distributed under the MIT License. See LICENSE.txt
for more information.