Tx dbeab29ec769a396b9caa3dd25788ae92e13559b@43626377

Included in block 43,626,377 at 2020-05-23 18:31:24 (UTC)


Raw transaction

ref_block_num44,915
ref_block_prefix3,197,732,470
expiration2020-05-23 18:41:18
operations
0.
0.comment
1.
parent_authorskepticology
parent_permlinklive-feed-of-posts-and-comments-beginner-python-tutorial
authorskepticology
permlinkq7kdhy
title""
body"This program was updated with a mute list, language filter, author reputation, and character count.

````
from steem import Steem
from steem.blockchain import Blockchain
from steem.account import Account
from steem.post import Post
import math
steem = Steem(node='https://api.steemit.com')
blockchain = Blockchain()
stream = blockchain.stream(filter_by=['comment'])
mutelist = ["abusereports", "actifit", "alphaccino.art", "arcange", "bdvoter.cur", "build-it.curator", "boomerang", "cheetah", "crystalliu", "curationkiwi", "dlease", "drotto", "giphy", "innerblocks", "innerhive", "likwid", "marcocasario", "ngc", "opgaming", "patrice", "sirvotesalot", "steembots.info", "steemexplorers", "steemitboard", "steem-ua", "tipu", "thecyclist", "trendotoken", "upvotebank", "upvotefromme", "xx0xx", "xxxxxxxxxx", "whalepromobot", "z8teyb289qav9z"]
def isLanguage(postbody):
try:
postbody.encode(encoding='utf-8').decode('ascii')
except UnicodeDecodeError:
return False
else:
return True
while True:
try:
for post in stream:
postauthor = post["author"]
posttitle = post["title"]
postbody = post["body"]
permlink = post["permlink"]
postparent = post['parent_author']
postlink = "https://www.steemit.com/@" + postauthor + "/" + permlink
if postauthor not in mutelist:
if(isLanguage(postbody)):
print('\033[94m' + postlink)
if(posttitle):
if "@@" in postbody:
reputation = float(steem.get_account(postauthor)["reputation"])
rep = int((math.log10(abs(reputation))-9)*9)+25
print('\033[91m' + '(' + str(rep) + ')' + postauthor + ' edited ' + posttitle + '.\n' + '\033[0m' + postbody[0:500])
else:
reputation = float(steem.get_account(postauthor)["reputation"])
rep = int((math.log10(abs(reputation))-9)*9)+25
print('\033[92m' + '(' + str(rep) + ')' + postauthor + ' posted ' + posttitle + '.\n' + '\033[0m' + postbody[0:500])
else:
if "@@" in postbody:
reputation = float(steem.get_account(postauthor)["reputation"])
rep = int((math.log10(abs(reputation))-9)*9)+25
print('\033[91m' + '(' + str(rep) + ')' + postauthor + ' edited comment to ' + postparent + '.\n' + '\033[0m' + postbody[0:500])
else:
reputation = float(steem.get_account(postauthor)["reputation"])
rep = int((math.log10(abs(reputation))-9)*9)+25
print('\033[93m' + '(' + str(rep) + ')' + postauthor + ' replied to ' + postparent + '.\n' + '\033[0m' + postbody[0:500])
print('--------------------------------------------------------------')
except Exception as error:
print(repr(error))
````"
json_metadata{"tags":["steem"],"app":"steempeak/2020.05.1"}
extensions[]
signatures
0.1f22098998ec2ad453f7925484751b09fdd9de071ff7e4fc89843b1d2a489197df2267e5376767ef724686ad4817ce609f14673a48cf730bf1053e4d0bb9416064
transaction_iddbeab29ec769a396b9caa3dd25788ae92e13559b
block_num43,626,377
transaction_num3