The rationale for choosing \(weight\_ratio\_cap = 4\) is as a compromise between not allowing any prioritization of transactions relative to those that pay the conventional fee, and allowing arbitrary prioritization based on ability to pay.
+Calculating + \(tx.\!weight\_ratio\) + in terms of + \(\mathsf{max}(1,\, tx.\!fee)\) + rather than just + \(tx.\!fee\) + avoids needing to define "with probability in direct proportion to its + \(weight\_ratio\!\) + " for the case where all remaining candidate transactions would have + \(weight\_ratio = 0\!\) + .
Miners have an incentive to make this change because:
diff --git a/zip-0317.rst b/zip-0317.rst index 36363446..86f46569 100644 --- a/zip-0317.rst +++ b/zip-0317.rst @@ -283,18 +283,18 @@ from a set of transactions in a node's mempool: conventional fee: a. Pick one of those transactions at random with probability in direct - proportion to its weight ratio, and remove it from the set of candidate - transactions. Let :math:`B` be the block template with this transaction - included. + proportion to its :math:`weight\_ratio`, and remove it from the set of + candidate transactions. Let :math:`B` be the block template with this + transaction included. b. If :math:`B` would be within the block size limit and block sigop limit [#sigop-limit]_, add the transaction to the block template. 3. Repeat while there is any candidate transaction: a. Pick one of those transactions at random with probability in direct - proportion to its weight ratio, and remove it from the set of candidate - transactions. Let :math:`B` be the block template with this transaction - included. + proportion to its :math:`weight\_ratio`, and remove it from the set of + candidate transactions. Let :math:`B` be the block template with this + transaction included. b. If :math:`B` would be within the block size limit and block sigop limit [#sigop-limit]_ and :math:`block\_unpaid\_actions(B) \leq block\_unpaid\_action\_limit\!`, add the transaction to the block template. @@ -338,6 +338,11 @@ between not allowing any prioritization of transactions relative to those that pay the conventional fee, and allowing arbitrary prioritization based on ability to pay. +Calculating :math:`tx.\!weight\_ratio` in terms of :math:`\mathsf{max}(1,\, tx.\!fee)` +rather than just :math:`tx.\!fee` avoids needing to define "with probability in direct +proportion to its :math:`weight\_ratio\!`" for the case where all remaining candidate +transactions would have :math:`weight\_ratio = 0\!`. + Incentive compatibility for miners ''''''''''''''''''''''''''''''''''