Jefferson-Henrique / GetOldTweets-python

A project written in Python to get old tweets, it bypass some limitations of Twitter Official API.
MIT License
1.35k stars 809 forks source link

Getting mentions and hashtags #267

Open thaleslr opened 4 years ago

thaleslr commented 4 years ago

Hey guys,

I am having some trouble while getting mentions and hashtags from the queries. I used the standard files from the github but everytime I get only '@' or '#' instead of mentions or hashtags.

I was having the same problem for usernames, but I fixed it switching from Python 3.6.9 to 2.7.17.

Has anyone ever had this issue?

As an example: ### Example 2 - Get tweets by query search [europe refugees] Username: jerranspearman3 Retweets: 0 Text: [106] Europe's Refugees & American Elections w/ Chris Hedges https://youtu.be/GYqgj3l4r18  via @ YouTube Mentions: @ Hashtags:

Thanks a lot!

rijalfm25 commented 4 years ago

I just edited some code in TweetManager.py to get exactly hastags and mentions from the tweet

rijalfm25 commented 4 years ago

Because in original code, to scrape hastag or mentions from the tweet just using regex from tweet text not from the data.