Last active
April 13, 2020 22:57
-
-
Save TheCrazyGM/211971c52f46feb7bb510fdf741675eb to your computer and use it in GitHub Desktop.
bsting - remove all delegations that carried over from Steem to Hive
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import getpass | |
from pprint import pprint | |
from beem import Steem | |
from beem.account import Account | |
from beem.wallet import Wallet | |
active_wif = getpass.getpass(prompt='Active key: ') | |
hv = Steem(node="http://anyx.io", keys=[active_wif]) | |
w = Wallet(steem_instance=hv) | |
usr = w.getAccountFromPrivateKey(active_wif) | |
a = Account(usr, steem_instance=hv) | |
deleg = a.get_vesting_delegations() | |
for x in deleg: | |
delegatee = x['delegatee'] | |
print(f'[Dropping delegation to {delegatee} to 0]') | |
pprint(a.delegate_vesting_shares(delegatee, 0)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment