Viewing a response to: @maxg/re-steempytutorials-daily-steem-python-challenge-8-win-1-steem-20180120t204958942z
Just tested it and there are some tiny errors, but if you fix them, then it works as specified! Go, go, go, if you are quick you can still win!
author | amosbastian |
---|---|
permlink | re-maxg-re-steempytutorials-daily-steem-python-challenge-8-win-1-steem-20180121t140830906z |
category | contest |
json_metadata | {"tags":["contest"],"app":"steemit/0.1"} |
created | 2018-01-21 14:08:30 |
last_update | 2018-01-21 14:11:18 |
depth | 2 |
children | 3 |
last_payout | 2018-01-28 14:08:30 |
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 | 143 |
author_reputation | 174,473,586,900,705 |
root_title | "Daily Steem-Python Challenge #8, Win 1 Steem!" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 31,114,994 |
net_rshares | 0 |
😇
author | emrebeyler |
---|---|
permlink | re-amosbastian-re-maxg-re-steempytutorials-daily-steem-python-challenge-8-win-1-steem-20180121t142713754z |
category | contest |
json_metadata | {"tags":["contest"],"app":"steemit/0.1"} |
created | 2018-01-21 14:27:12 |
last_update | 2018-01-21 14:27:12 |
depth | 3 |
children | 0 |
last_payout | 2018-01-28 14:27:12 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.048 HBD |
curator_payout_value | 0.012 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 1 |
author_reputation | 448,535,049,068,622 |
root_title | "Daily Steem-Python Challenge #8, Win 1 Steem!" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 31,119,215 |
net_rshares | 5,341,674,648 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
turbot | 0 | 5,341,674,648 | 100% |
Cleaned and updated! There was one pretty big error with how I was calculating voting power. The voting power param set on the account object is your VP at the last time you voted. So you need to do some math with the last vote time to figure out your current real voting power. ``` def calc_vote_power(account): vp = account['voting_power'] last = datetime.strptime(account['last_vote_time'], "%Y-%m-%dT%H:%M:%S") diff = datetime.utcnow().timestamp() - last.timestamp() return (vp + 1e4 * diff / 432e3) / 10000 ``` I actually had to find this one by going through the source code for [steemnow](https://www.steemnow.com/@maxg)  Other than that it was just import errors and the like :P
author | maxg |
---|---|
permlink | re-amosbastian-re-maxg-re-steempytutorials-daily-steem-python-challenge-8-win-1-steem-20180121t164425662z |
category | contest |
json_metadata | {"tags":["contest"],"image":["https://steemitimages.com/DQmZF75n9KMfq6sjwQ385bvk4DZQtezCW3kvBBs2f5A1kkt/image.png"],"links":["https://www.steemnow.com/@maxg"],"app":"steemit/0.1"} |
created | 2018-01-21 16:44:24 |
last_update | 2018-01-21 16:44:24 |
depth | 3 |
children | 1 |
last_payout | 2018-01-28 16:44:24 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.054 HBD |
curator_payout_value | 0.018 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 790 |
author_reputation | 5,859,582,764,121 |
root_title | "Daily Steem-Python Challenge #8, Win 1 Steem!" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 31,148,541 |
net_rshares | 6,821,979,169 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
amosbastian | 0 | 6,821,979,169 | 100% |
O wow, I didn't know that about voting power! I just sent you the STEEM, congratulations!
author | amosbastian |
---|---|
permlink | re-maxg-re-amosbastian-re-maxg-re-steempytutorials-daily-steem-python-challenge-8-win-1-steem-20180121t183625316z |
category | contest |
json_metadata | {"tags":["contest"],"app":"steemit/0.1"} |
created | 2018-01-21 18:36:24 |
last_update | 2018-01-21 18:36:24 |
depth | 4 |
children | 0 |
last_payout | 2018-01-28 18:36: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 | 89 |
author_reputation | 174,473,586,900,705 |
root_title | "Daily Steem-Python Challenge #8, Win 1 Steem!" |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 31,171,230 |
net_rshares | 0 |