cosme12 / SimpleCoin

Just a really simple, insecure and incomplete implementation of a blockchain for a cryptocurrency made in Python as educational material. In other words, a simple Bitcoin clone.
http://copitosystem.com
MIT License
1.78k stars 397 forks source link

Added improvements at creating adress and new proof of work #15

Closed adanielpincab closed 6 years ago

adanielpincab commented 6 years ago

Now when you create your new address the keys are saved in a .txt file, in which you can copy/paste your direction and save it securely.

kennethgoodman commented 6 years ago

Should definitely include the hash of the previous block in PoW.

Can we switch it to something more simple and closer to BTC PoW:

if hash( previous_block + transactions + timestamp )[ :4] == "0000":
    break
adanielpincab commented 6 years ago

For now i have implemented the new pow without adding previous block hash. But i'll try to do it

adanielpincab commented 6 years ago

Ok, done! 😄 @kennethgoodman

cosme12 commented 6 years ago

Ok guys, lets do this the right way. I just created a new branch called v1.1.0. Lets push everything there, so we can test big changes without messing with the Master (we want other people to still be able to run it without problems). Then try to divide your pull request in as many pieces as possible. For example, typos should be in a pull request while saving keys to text file in another. This way we can accept the typos commit fast and focus on the real changes. And last, keep it really simple.

BTW thanks for helping 👍

adanielpincab commented 6 years ago

Ok, I've made a new pull request to the new branch, I'll delete this one.