 It is now trivially easy to update your witness with a few lines Python: ``` from steemtools.experimental import Transactions t = Transactions() props = { "account_creation_fee": "15.000 STEEM", "maximum_block_size": 65536, "sbd_interest_rate": 500, } tx = t.witness_update("furion", "<PUBLIC_POSTING_KEY>", "https://steemdb.com/@furion/witness", props, "<PRIVATE_ACTIVE_KEY>", sim_mode=False) pprint(tx) ``` **Outputs:** ``` {'expiration': '2016-09-21T19:50:27', 'extensions': [], 'operations': [['witness_update', {'block_signing_key': 'STM7WDG2QpThdkRa3G2PYXM7gH9UksoGm4xqoFBrNet6GH7ToNUYx', 'fee': '0.000 STEEM', 'owner': 'furion', 'props': {'account_creation_fee': '15.000 STEEM', 'maximum_block_size': 65536, 'sbd_interest_rate': 500}, 'url': 'https://steemdb.com/@furion/witness'}]], 'ref_block_num': 59959, 'ref_block_prefix': 4091806926, 'signatures': ['205afd9f3ac04...1bb0459320894e']} ```  **Why would you want to update your witness programmatically?** 1.) If you would like to stop minting blocks while your witness is offline, or being upgraded, then you should update your witness with an empty signing key `""` to avoid missing blocks. 2.) If you would like to do an automated failover to another server, you should change your signing key to avoid forking (very bad). 3.) Because its easier and more fun than cli_wallet. **Source** [> steemtools on GitHub](https://github.com/Netherdrake/steemtools) Big thanks to @jesta for the challenge. ------------------- <center>[](https://steemit.com/@furion) Don't miss out on the next post - follow me. [steemtools](https://github.com/Netherdrake/steemtools) | [steem.li](https://steem.li) | [witness](https://steemdb.com/@furion/witness) </center> -------------------
author | furion |
---|---|
permlink | updating-you-witness-with-python |
category | witness-category |
json_metadata | {"tags":["witness-category","steemtools"],"users":["jesta"],"image":["http://i.imgur.com/jVLWgAY.png","http://i.imgur.com/QT6T4PD.png","http://i.imgur.com/5MaAhy7.png"],"links":["https://github.com/Netherdrake/steemtools","https://steemit.com/@furion","https://steem.li","https://steemdb.com/@furion/witness"]} |
created | 2016-09-21 20:01:18 |
last_update | 2016-09-21 20:04:27 |
depth | 0 |
children | 4 |
last_payout | 2016-10-22 20:35:24 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 44.035 HBD |
curator_payout_value | 2.916 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 2,010 |
author_reputation | 116,503,940,714,958 |
root_title | "Updating your witness with Python" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 1,320,399 |
net_rshares | 31,923,236,014,489 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
barrie | 0 | 555,648,038,821 | 100% | ||
riverhead | 0 | 5,003,862,102,772 | 100% | ||
hr1 | 0 | 2,180,143,558,600 | 100% | ||
rossco99 | 0 | 1,078,541,390,046 | 100% | ||
liondani | 0 | 986,822,340,078 | 100% | ||
steemit200 | 0 | 5,445,816,729,094 | 100% | ||
joseph | 0 | 1,117,418,667,897 | 100% | ||
aizensou | 0 | 106,661,342,444 | 100% | ||
au1nethyb1 | 0 | 3,128,538,010,927 | 100% | ||
masteryoda | 0 | 415,606,800,658 | 100% | ||
recursive | 0 | 3,367,220,638,137 | 100% | ||
mineralwasser | 0 | 1,651,143,998 | 100% | ||
mrs.agsexplorer | 0 | 110,987,042,499 | 100% | ||
bingo-1 | 0 | 1,966,792,348 | 100% | ||
boatymcboatface | 0 | 519,784,403,628 | 100% | ||
proctologic | 0 | 28,636,366,129 | 100% | ||
idol | 0 | 6,067,078,828 | 100% | ||
sakr | 0 | 2,895,767,251 | 100% | ||
chitty | 0 | 262,130,284,080 | 100% | ||
patrice | 0 | 9,535,440,671 | 100% | ||
alexgr | 0 | 47,265,351,876 | 100% | ||
jocelyn | 0 | 1,094,801,611 | 100% | ||
cyan91 | 0 | 65,613,438,210 | 100% | ||
leesunmoo | 0 | 526,665,898,564 | 100% | ||
fkn | 0 | 23,156,278,915 | 100% | ||
james-show | 0 | 12,012,267,087 | 52% | ||
teamsteem | 0 | 314,654,367,385 | 100% | ||
elishagh1 | 0 | 29,782,660,253 | 100% | ||
richman | 0 | 11,218,678,212 | 100% | ||
nanzo-scoop | 0 | 725,508,652,204 | 100% | ||
fact | 0 | 12,797,974,208 | 100% | ||
mummyimperfect | 0 | 220,358,869,792 | 100% | ||
coar | 0 | 494,856,543 | 100% | ||
asch | 0 | 108,543,244,259 | 100% | ||
murh | 0 | 1,053,450,464 | 33.01% | ||
cryptofunk | 0 | 5,851,944,021 | 100% | ||
error | 0 | 1,360,483,855 | 100% | ||
andu | 0 | 13,072,810,183 | 100% | ||
theshell | 0 | 60,073,812,294 | 100% | ||
ak2020 | 0 | 61,600,779,181 | 100% | ||
kanoptx | 0 | 54,069,438,678 | 100% | ||
thecryptodrive | 0 | 47,364,105,769 | 100% | ||
bravenewcoin | 0 | 135,717,170,207 | 100% | ||
unonimity | 0 | 244,474,450 | 100% | ||
mark-waser | 0 | 7,072,413,342 | 100% | ||
kimziv | 0 | 127,727,178,143 | 78% | ||
emily-cook | 0 | 83,713,245,265 | 100% | ||
clement | 0 | 43,903,915,606 | 100% | ||
rubybian | 0 | 93,526,830,632 | 100% | ||
fabio | 0 | 387,799,113,357 | 100% | ||
r4fken | 0 | 37,280,935,978 | 100% | ||
derekareith | 0 | 197,674,363,673 | 100% | ||
furion | 0 | 118,260,504,670 | 100% | ||
barbara2 | 0 | 564,001,161 | 100% | ||
ch0c0latechip | 0 | 652,871,057 | 100% | ||
doge4lyf | 0 | 580,258,813 | 100% | ||
renohq | 0 | 1,269,139,003,003 | 100% | ||
ausbitbank | 0 | 17,621,506,996 | 100% | ||
steem1653 | 0 | 3,953,031,908 | 100% | ||
cynetyc | 0 | 183,390,577 | 100% | ||
jesta | 0 | 471,824,205,924 | 100% | ||
karen13 | 0 | 3,775,021,693 | 40% | ||
pigatto | 0 | 3,505,248,421 | 100% | ||
inertia | 0 | 80,193,861,545 | 100% | ||
creemej | 0 | 33,632,516,654 | 100% | ||
carlsalyer | 0 | 124,575,711 | 100% | ||
bitcoiner | 0 | 6,201,614,045 | 100% | ||
tarindel | 0 | 4,284,546,059 | 100% | ||
rainchen | 0 | 5,653,036,079 | 100% | ||
jl777 | 0 | 183,478,996,889 | 40% | ||
streak | 0 | 51,021,382 | 100% | ||
positive | 0 | 18,779,372,681 | 100% | ||
biternator | 0 | 115,172,368 | 100% | ||
anca3drandom | 0 | 34,404,271,885 | 100% | ||
proto | 0 | 15,330,836,459 | 40% | ||
sisterholics | 0 | 21,860,751,198 | 78% | ||
alex.chien | 0 | 1,562,716,808 | 100% | ||
michaeldodridge | 0 | 17,483,388,263 | 100% | ||
fnait | 0 | 678,425,528 | 100% | ||
keepcalmand | 0 | 584,225,612 | 100% | ||
glitterpig | 0 | 3,702,659,746 | 100% | ||
picker | 0 | 119,294,413 | 100% | ||
jed78 | 0 | 8,071,295,884 | 100% | ||
steemdrive | 0 | 152,278,391,112 | 100% | ||
taker | 0 | 7,758,546,279 | 40% | ||
laonie | 0 | 766,062,635,010 | 78% | ||
myfirst | 0 | 22,776,210,150 | 78% | ||
somebody | 0 | 156,440,591,552 | 78% | ||
sunshine | 0 | 16,587,083,515 | 100% | ||
flysaga | 0 | 5,845,948,632 | 78% | ||
midnightoil | 0 | 34,220,216,065 | 78% | ||
michellek | 0 | 55,648,603 | 100% | ||
steemleak | 0 | 3,166,845,626 | 100% | ||
xiaohui | 0 | 83,657,894,084 | 75% | ||
riosparada | 0 | 548,987,876 | 100% | ||
jphamer1 | 0 | 21,151,855,297 | 100% | ||
elfkitchen | 0 | 4,196,233,334 | 78% | ||
joele | 0 | 121,676,629,318 | 100% | ||
xiaokongcom | 0 | 2,855,189,323 | 78% | ||
steemitqa | 0 | 6,397,173,526 | 100% | ||
cristi | 0 | 19,012,153,858 | 100% | ||
jrcornel | 0 | 5,105,019,661 | 100% | ||
xianjun | 0 | 5,445,689,985 | 78% | ||
bledarus | 0 | 1,803,939,128 | 100% | ||
bitcalm | 0 | 40,882,308,170 | 100% | ||
microluck | 0 | 370,354,434 | 78% | ||
kyriacos | 0 | 13,192,415,880 | 39% | ||
pjheinz | 0 | 16,291,241,445 | 100% | ||
redferne | 0 | 58,944,338 | 100% | ||
helikopterben | 0 | 159,715,354,859 | 100% | ||
gammagooblin | 0 | 1,873,411,908 | 100% | ||
cryptomancer | 0 | 13,013,957,836 | 100% | ||
netaterra | 0 | 3,051,884,988 | 100% | ||
bitchplease | 0 | 52,011,354 | 100% | ||
ontofractal | 0 | 1,311,637,227 | 100% | ||
ats-david | 0 | 7,232,133,299 | 100% | ||
jfeenstra | 0 | 50,130,654 | 100% | ||
richardcrill | 0 | 4,263,580,919 | 100% | ||
laonie11 | 0 | 13,747,137,503 | 80% | ||
eight-rad | 0 | 2,059,843,335 | 100% | ||
davidjkelley | 0 | 1,701,208,800 | 100% | ||
greatness | 0 | 746,635,111 | 100% | ||
sponge-bob | 0 | 11,112,192,721 | 20% | ||
digital-wisdom | 0 | 15,956,009,729 | 100% | ||
ethical-ai | 0 | 3,801,855,300 | 100% | ||
jwaser | 0 | 7,542,912,791 | 100% | ||
foti | 0 | 0 | 100% | ||
bwaser | 0 | 2,740,579,437 | 100% | ||
jeff-kubitz | 0 | 57,318,311 | 100% | ||
alina1 | 0 | 119,180,426 | 100% | ||
brains | 0 | 11,109,970,230 | 20% | ||
z3r0d4yz | 0 | 551,631,336 | 100% | ||
portuguesinha | 0 | 948,556,918 | 100% | ||
ellepdub | 0 | 2,528,262,288 | 100% | ||
herpetologyguy | 0 | 17,212,841,557 | 100% | ||
morgan.waser | 0 | 4,935,036,539 | 100% | ||
lexikon082 | 0 | 58,262,637 | 100% | ||
linkback-bot-v0 | 0 | 61,216,165 | 100% | ||
donchate | 0 | 4,986,270,440 | 100% | ||
strong-ai | 0 | 3,779,995,784 | 100% | ||
uct | 0 | 159,730,645 | 100% | ||
front | 0 | 159,716,853 | 100% | ||
iberia | 0 | 158,676,075 | 100% | ||
shadowcash | 0 | 158,529,766 | 100% | ||
shadowproject | 0 | 158,523,226 | 100% | ||
cybergirl | 0 | 157,706,877 | 100% | ||
rage | 0 | 157,118,197 | 100% | ||
blender | 0 | 156,411,729 | 100% | ||
tipsandtricks | 0 | 156,299,377 | 100% | ||
bosch | 0 | 156,262,128 | 100% | ||
stimmt | 0 | 156,194,471 | 100% | ||
disneypixar | 0 | 156,043,541 | 100% | ||
steemwallet | 0 | 155,619,923 | 100% | ||
cream | 0 | 155,522,158 | 100% | ||
steemthis | 0 | 155,451,903 | 100% | ||
citigroup | 0 | 155,433,319 | 100% | ||
steemtruth | 0 | 1,853,458,331 | 100% | ||
steemq-funds | 0 | 130,782,812 | 100% | ||
wr4second | 0 | 0 | 100% | ||
drakos | 0 | 0 | 100% |
It is actually always easier with the cli_wallet, assuming u know what to do. :D
author | aizensou |
---|---|
permlink | re-furion-updating-you-witness-with-python-20160921t201319900z |
category | witness-category |
json_metadata | {"tags":["witness-category"]} |
created | 2016-09-21 20:13:18 |
last_update | 2016-09-21 20:13:18 |
depth | 1 |
children | 2 |
last_payout | 2016-10-22 20:35:24 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.000 HBD |
curator_payout_value | 0.000 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 80 |
author_reputation | 31,620,973,634,639 |
root_title | "Updating your witness with Python" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 1,320,496 |
net_rshares | 0 |
Perhaps I should elaborate what I meant by easier. With a Python script, you can re-run it at anytime, as well as have it be part of the automated system. To be fair, you could also do this with the wallet RPC, so now that I think of it, its not a super valid point anymore :) The more fun part subjectively still stands :)
author | furion |
---|---|
permlink | re-aizensou-re-furion-updating-you-witness-with-python-20160921t203319029z |
category | witness-category |
json_metadata | {"tags":["witness-category"]} |
created | 2016-09-21 20:33:18 |
last_update | 2016-09-21 20:33:18 |
depth | 2 |
children | 0 |
last_payout | 2016-10-22 20:35:24 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.000 HBD |
curator_payout_value | 0.000 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 323 |
author_reputation | 116,503,940,714,958 |
root_title | "Updating your witness with Python" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 1,320,643 |
net_rshares | 0 |
author | jesta |
---|---|
permlink | re-aizensou-re-furion-updating-you-witness-with-python-20160921t202134687z |
category | witness-category |
json_metadata | {"tags":["witness-category"]} |
created | 2016-09-21 20:21:33 |
last_update | 2016-09-21 20:21:33 |
depth | 2 |
children | 0 |
last_payout | 2016-10-22 20:35:24 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.026 HBD |
curator_payout_value | 0.000 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 66 |
author_reputation | 140,605,453,893,072 |
root_title | "Updating your witness with Python" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 1,320,576 |
net_rshares | 159,346,256,360 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
aizensou | 0 | 104,303,896,382 | 100% | ||
murh | 0 | 1,053,453,084 | 33.01% | ||
furion | 0 | 53,988,906,894 | 44% |
So awesome, thank you for toiling away on this. I've been fighting with the same issues you initially encountered while I've been experimenting with this. Big kudos to putting your effort into it and getting it done. I'll be using this for my witness nodes now to assist in automatic failover!
author | jesta |
---|---|
permlink | re-furion-updating-you-witness-with-python-20160921t202249233z |
category | witness-category |
json_metadata | {"tags":["witness-category"]} |
created | 2016-09-21 20:22:48 |
last_update | 2016-09-21 20:22:48 |
depth | 1 |
children | 0 |
last_payout | 2016-10-22 20:35:24 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.027 HBD |
curator_payout_value | 0.000 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 295 |
author_reputation | 140,605,453,893,072 |
root_title | "Updating your witness with Python" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 1,320,580 |
net_rshares | 161,393,610,298 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
aizensou | 0 | 104,303,896,382 | 100% | ||
furion | 0 | 53,988,906,894 | 44% | ||
bitcoiner | 0 | 3,100,807,022 | 50% |