crawl only mentions, no replies
This commit is contained in:
parent
dc8f51c632
commit
24598f0b87
|
@ -50,11 +50,13 @@ class TwitterBot(Bot):
|
||||||
text = re.sub(
|
text = re.sub(
|
||||||
"(?<=^|(?<=[^a-zA-Z0-9-_\.]))@([A-Za-z]+[A-Za-z0-9-_]+)",
|
"(?<=^|(?<=[^a-zA-Z0-9-_\.]))@([A-Za-z]+[A-Za-z0-9-_]+)",
|
||||||
"", status.text)
|
"", status.text)
|
||||||
reports.append(report.Report(status.author.screen_name,
|
username = api.me()
|
||||||
self,
|
if username in status.text:
|
||||||
text,
|
reports.append(report.Report(status.author.screen_name,
|
||||||
status.id,
|
self,
|
||||||
status.created_at))
|
text,
|
||||||
|
status.id,
|
||||||
|
status.created_at))
|
||||||
user.save_seen_tweet(status.id)
|
user.save_seen_tweet(status.id)
|
||||||
return reports
|
return reports
|
||||||
except tweepy.RateLimitError:
|
except tweepy.RateLimitError:
|
||||||
|
|
Loading…
Reference in a new issue