Skip to content

Commit

Permalink
Fix Decimal / Float bug 1/2
Browse files Browse the repository at this point in the history
  • Loading branch information
EggPool authored Nov 28, 2019
1 parent da82712 commit 99c159b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion digest.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ def process_transactions(block):
if block_instance.mining_reward < 0.5:
block_instance.mining_reward = 0.5

reward = '{:.8f}'.format(block_instance.mining_reward + sum(fees_block))
reward = '{:.8f}'.format(Decimal(block_instance.mining_reward) + sum(fees_block))

# don't request a fee for mined block so new accounts can mine
fee = 0
Expand Down

0 comments on commit 99c159b

Please sign in to comment.