Skip to content

Instantly share code, notes, and snippets.


Diego Pino dpino

View GitHub Profile
dpino /
Last active Jan 4, 2019 — forked from aunyks/
The code in this gist isn't as succinct as I'd like it to be. Please bare with me and ask plenty of questions that you may have about it.
#!/usr/bin/env python
# Source
# Modifications:
# - Can pass port number as command line argument.
# - Added GET method /add_peer.
# - On retrieving blockchain, call consensus to synchronize with other peers.
# - On updating the current blockchain from a peers' blockchain, convert list
# of JSON blocks to native Block objects.
You can’t perform that action at this time.