From 8fdbaece3d3f554fbbbbe44ea6efaa8620d10b32 Mon Sep 17 00:00:00 2001 From: ayushkumar63123 <86553805+ayushkumar63123@users.noreply.github.com> Date: Mon, 29 Nov 2021 16:18:51 +0530 Subject: [PATCH] Removing Syntax Errors I have removed syntax errors from your code. If you want to thank, I will appreciate. And if you reward me on my TRX wallet, I won't complain. In fact, I would appreciate even more. --- pybgl/classes/block.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pybgl/classes/block.py b/pybgl/classes/block.py index 5a1d400..9d4909e 100644 --- a/pybgl/classes/block.py +++ b/pybgl/classes/block.py @@ -251,14 +251,14 @@ def mn(self, nonce): header = self.h1 + s2rh(nonce) + self.h1 return sha3_256(header, 1) - cb = self.coinb1 + extra_nonce_1 + extra_nonce_2 + self.coinb2 - time = s2rh(time) + cb = self.coinb1 + BlockTemplate.extra_nonce_1 + BlockTemplate.extra_nonce_2 + self.coinb2 + time = s2rh(Block.time) bits = s2rh(self.bits) nonce = s2rh(nonce) cbh = sha3_256(bytes_from_hex(cb)) c = Transaction(cb) merkle_root = merkle_root_from_branches(self.merkle_branches, cbh) - header = version + prev_hash + merkle_root + time + bits + nonce + header = Block.version + BlockTemplate.prev_hash + merkle_root + Block.time + bits + nonce block = header.hex() block +=int_to_var_int(len (self.transactions) + 1).hex() block += cb