mirror of
https://gitlab.com/jeancf/twoot.git
synced 2024-11-23 20:11:11 +00:00
Improved logging message of cap limit
This commit is contained in:
parent
0637c8ccda
commit
200837c336
4
twoot.py
4
twoot.py
|
@ -513,13 +513,11 @@ def main(argv):
|
|||
# post each on Mastodon and record it in database
|
||||
# **********************************************************
|
||||
|
||||
if cap != 0:
|
||||
logging.info('# of toots to post capped to %d', cap)
|
||||
|
||||
posted_cnt = 0
|
||||
for tweet in reversed(tweets):
|
||||
# Check if we have reached the cap on the number of toots to post
|
||||
if cap != 0 and posted_cnt >= cap:
|
||||
logging.info('%d toots not posted due to configured cap', len(tweets) - cap)
|
||||
break
|
||||
|
||||
logging.debug('Uploading Tweet %s', tweet["tweet_id"])
|
||||
|
|
Loading…
Reference in New Issue
Block a user