mirror of
https://gitlab.com/jeancf/twoot.git
synced 2025-02-17 13:58: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
|
# 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
|
posted_cnt = 0
|
||||||
for tweet in reversed(tweets):
|
for tweet in reversed(tweets):
|
||||||
# Check if we have reached the cap on the number of toots to post
|
# Check if we have reached the cap on the number of toots to post
|
||||||
if cap != 0 and posted_cnt >= cap:
|
if cap != 0 and posted_cnt >= cap:
|
||||||
|
logging.info('%d toots not posted due to configured cap', len(tweets) - cap)
|
||||||
break
|
break
|
||||||
|
|
||||||
logging.debug('Uploading Tweet %s', tweet["tweet_id"])
|
logging.debug('Uploading Tweet %s', tweet["tweet_id"])
|
||||||
|
|
Loading…
Reference in New Issue
Block a user