Skip to content
This repository has been archived by the owner on May 23, 2023. It is now read-only.

Commit

Permalink
Add gaslimit upper bound of 2**63-1 EIP 106
Browse files Browse the repository at this point in the history
  • Loading branch information
konradkonrad committed Jul 8, 2016
1 parent a1ffdbc commit 03e1c88
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ethereum/blocks.py
Original file line number Diff line number Diff line change
Expand Up @@ -446,6 +446,9 @@ def __init__(self, header, transaction_list=[], uncles=[], env=None,
if self.timestamp >= 2 ** 256:
raise ValueError("Timestamp waaaaaaaaaaayy too large")

if self.gas_limit > 2 ** 63 - 1:
raise ValueError("Block's gaslimit went too high!")

for uncle in uncles:
assert isinstance(uncle, BlockHeader)

Expand Down

0 comments on commit 03e1c88

Please sign in to comment.