Skip to content

Commit

Permalink
Update some more obvious documentation around PoW; add newsfragment
Browse files Browse the repository at this point in the history
  • Loading branch information
fselmo committed Sep 6, 2023
1 parent 163ea50 commit 0605f01
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
13 changes: 11 additions & 2 deletions docs/guides/understanding_the_mining_process.rst
Original file line number Diff line number Diff line change
@@ -1,12 +1,21 @@
Understanding the mining process
================================

.. note::

Proof-of-Work (PoW) mining is no longer used for achieving consensus on Ethereum.
Newer virtual machines, beginning with the ``ParisVM``, assume a
Proof-of-Stake (PoS) consensus mechanism which lies beyond the scope of the
execution layer. This guide is for educational purposes only.


From the :doc:`Cookbook </cookbook/index>` we can already learn how to
use the :class:`~eth.chains.base.Chain` class to create a single
blockchain as a combination of different virtual machines for different spans
of blocks.

In this guide we want to build up on that knowledge and look into the actual mining process.
In this guide we want to build up on that knowledge and look into the actual mining
process that was once important for achieving consensus on mainnet Ethereum.


.. note::
Expand Down Expand Up @@ -134,7 +143,7 @@ briefly go over an example that demonstrates how we can retrieve a matching
Py-EVM currently doesn't offer a stable API for actual PoW mining. The following code is for
demonstration purpose only.

Mining on the main ethereum chain is a competition done simultanously by many miners, hence the
Mining on the main ethereum chain is a competition done simultaneously by many miners, hence the
*mining difficulty* is pretty high which means it will take a very long time to find the right
``nonce`` and ``mix_hash`` on commodity hardware. In order for us to have something that we can
tinker with on a regular laptop, we'll construct a test chain with the ``difficulty`` set to ``1``.
Expand Down
1 change: 1 addition & 0 deletions newsfragments/2121.breaking.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Remove dependency on ``pyethash``, ``pysha3``, and ``pycryptodome`` packages and internalize the ethash algorithm implementation into Python code with significant loss of performance, in an effort to un-prioritize proof-of-work consensus and logic.

0 comments on commit 0605f01

Please sign in to comment.