Skip to content
This repository was archived by the owner on Mar 5, 2020. It is now read-only.

Commit c598f4c

Browse files
authored
Merge pull request #39 from EOSArgentina/master
Set TAPOS info when calling cleos in claim.py
2 parents 9ab968d + e069ba3 commit c598f4c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

eosio.unregd/claim.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ def get_tapos_info(block_id):
6363
msghash = keccak_256(msg).digest()
6464

6565
v, r, s = ecdsa_raw_sign(msghash, encode_privkey(priv,'hex').decode('hex'))
66-
signature = '00%x%x%x' % (v,r,s)
66+
signature = '00%02x%064x%064x' % (v,r,s)
6767

6868
if is_canonical(bytearray(signature.decode('hex'))):
6969
break
@@ -79,7 +79,7 @@ def get_tapos_info(block_id):
7979
}))
8080

8181
with open(os.devnull, 'w') as devnull:
82-
cmd = ["cleos","-u", API_URL, "push", "action", "eosio.unregd", "regaccount", tempf, "-p", pusher]
82+
cmd = ["cleos","-u", API_URL, "push", "action", "-r", block_id, "eosio.unregd", "regaccount", tempf, "-p", pusher]
8383
p = Popen(cmd)
8484
output, err = p.communicate("")
8585

0 commit comments

Comments
 (0)