create account

RE: [ANN] steemtools - A High-Level Python library for Steem by furion

View this thread on: hive.blogpeakd.comecency.com

Viewing a response to: @furion/ann-steemtools-a-high-level-python-library-for-steem

· @furion ·
$0.03
If you don't have a local node (its highly recommended to have a local node for use of this library), you will need to get the develop version of `piston` installed, to get the automatic fallback to remote node (new feature in python-steemlib, not on master yet).

Just run this after installing steemtools:
```
pip install --upgrade --no-deps --force-reinstall  git+git://github.com/xeroc/piston@develop
pip install --upgrade --no-deps --force-reinstall  git+git://github.com/xeroc/python-steemlib@develop
pip install --upgrade --no-deps --force-reinstall  git+git://github.com/xeroc/python-graphenelib@develop
```
👍  , , ,
properties (23)
authorfurion
permlinkre-furion-ann-steemtools-a-high-level-python-library-for-steem-20160913t115112382z
categorysteemtools
json_metadata{"tags":["steemtools"]}
created2016-09-13 11:51:12
last_update2016-09-13 11:51:12
depth1
children5
last_payout2016-10-15 04:22:03
cashout_time1969-12-31 23:59:59
total_payout_value0.029 HBD
curator_payout_value0.002 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length615
author_reputation116,503,940,714,958
root_title"[ANN] steemtools - A High-Level Python library for Steem"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id1,230,784
net_rshares157,862,314,108
author_curate_reward""
vote details (4)
@cryptomental · (edited)
Exception: Block is None. Are you trying to fetch a block from the future?

Hmm any idea what could have gone wrong? I have a fresh Ubuntu 16.04 64bit + pyenv named pysteem:

```
(pysteem) 09:08:45 (master)/sandbox/steemtools$ pip install --upgrade --no-deps --force-reinstall  git+git://github.com/xeroc/piston@develop
Collecting git+git://github.com/xeroc/piston@develop
  Cloning git://github.com/xeroc/piston (to develop) to /tmp/pip-04vpcgco-build
Installing collected packages: steem-piston
  Found existing installation: steem-piston 0.3.3
    Uninstalling steem-piston-0.3.3:
      Successfully uninstalled steem-piston-0.3.3
  Running setup.py install for steem-piston ... done
Successfully installed steem-piston-0.3.3
(pysteem) 09:08:54 (master) /sandbox/steemtools$ pip install --upgrade --no-deps --force-reinstall  git+git://github.com/xeroc/python-steemlib@develop
Collecting git+git://github.com/xeroc/python-steemlib@develop
  Cloning git://github.com/xeroc/python-steemlib (to develop) to /tmp/pip-67_ya3r5-build
Installing collected packages: steem
  Found existing installation: steem 0.2.2
    Uninstalling steem-0.2.2:
      Successfully uninstalled steem-0.2.2
  Running setup.py install for steem ... done
Successfully installed steem-0.2.2
(pysteem) 09:09:17 (master) /sandbox/steemtools$ pip install --upgrade --no-deps --force-reinstall  git+git://github.com/xeroc/python-graphenelib@develop
Collecting git+git://github.com/xeroc/python-graphenelib@develop
  Cloning git://github.com/xeroc/python-graphenelib (to develop) to /tmp/pip-ywwee05e-build
Installing collected packages: graphenelib
  Found existing installation: graphenelib 0.4.5
    Uninstalling graphenelib-0.4.5:
      Successfully uninstalled graphenelib-0.4.5
  Running setup.py install for graphenelib ... done
Successfully installed graphenelib-0.4.5
(pysteem) 09:09:34 (master) /sandbox/steemtools$ python examples/blockchain.py 
Lost connection to node during wsconnect(): ws://127.0.0.1:8090 (1/-1) Retrying in 0 seconds
Please provide a password for the new wallet
Passphrase: 
Confirm Passphrase: 
Traceback (most recent call last):
  File "examples/blockchain.py", line 6, in <module>
    for event in Blockchain().replay():
  File "/sandbox/pysteem/lib/python3.5/site-packages/steemtools-1-py3.5.egg/steemtools/blockchain.py", line 53, in replay
Exception: Block is None. Are you trying to fetch a block from the future?
```

Timezone is GMT+2 (9:08 - it is currently 21:08 Berlin time).
👍  
properties (23)
authorcryptomental
permlinkre-furion-re-furion-ann-steemtools-a-high-level-python-library-for-steem-20160913t191321095z
categorysteemtools
json_metadata{"tags":["steemtools"]}
created2016-09-13 19:13:21
last_update2016-09-13 19:15:09
depth2
children4
last_payout2016-10-15 04:22:03
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length2,489
author_reputation6,756,831,217,523
root_title"[ANN] steemtools - A High-Level Python library for Steem"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id1,235,088
net_rshares157,568,604
author_curate_reward""
vote details (1)
@furion · (edited)
Good catch. Try `for event in Blockchain().replay(start_block=1)`

I have been refactoring a lot today, and I forgot that the blocks start at 1 (default is 0). Will push a bugfix update out asap.
Edit: The bugfix is out,  `pip install --upgrade steemtools`
👍  ,
properties (23)
authorfurion
permlinkre-cryptomental-re-furion-re-furion-ann-steemtools-a-high-level-python-library-for-steem-20160913t191915566z
categorysteemtools
json_metadata{"tags":["steemtools"]}
created2016-09-13 19:19:15
last_update2016-09-13 19:31:36
depth3
children3
last_payout2016-10-15 04:22:03
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length256
author_reputation116,503,940,714,958
root_title"[ANN] steemtools - A High-Level Python library for Steem"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id1,235,171
net_rshares3,902,535,297
author_curate_reward""
vote details (2)
@cryptomental ·
Yes, that was it! Thank you.
properties (22)
authorcryptomental
permlinkre-furion-re-cryptomental-re-furion-re-furion-ann-steemtools-a-high-level-python-library-for-steem-20160913t193042149z
categorysteemtools
json_metadata{"tags":["steemtools"]}
created2016-09-13 19:30:42
last_update2016-09-13 19:30:42
depth4
children0
last_payout2016-10-15 04:22:03
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length28
author_reputation6,756,831,217,523
root_title"[ANN] steemtools - A High-Level Python library for Steem"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id1,235,302
net_rshares0
@cryptomental ·
Ok, I looked around and can say that this is an **extremely useful and powerful toy**. Double upvote.
properties (22)
authorcryptomental
permlinkre-furion-re-cryptomental-re-furion-re-furion-ann-steemtools-a-high-level-python-library-for-steem-20160913t194527533z
categorysteemtools
json_metadata{"tags":["steemtools"]}
created2016-09-13 19:45:27
last_update2016-09-13 19:45:27
depth4
children1
last_payout2016-10-15 04:22:03
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length101
author_reputation6,756,831,217,523
root_title"[ANN] steemtools - A High-Level Python library for Steem"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id1,235,474
net_rshares0