Last active
January 6, 2017 03:10
-
-
Save tantofish/ff3004653943e94cb8af370de813a66b to your computer and use it in GitHub Desktop.
Sample of reading ajax response of twitter timeline next scroll
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>>> import json | |
>>> data_file = open('/Users/yutu/Desktop/json') | |
>>> data = json.load(data_file) | |
>>> parsed_data = BeautifulSoup(data.get('items_html'),"html.parser") | |
>>> tweets_html = src.findAll('p',attrs={'class':'tweet-text'}) | |
>>> tweets_text = [x.getText() for x in tweets_html] | |
>>> for tweet in tweets_text: | |
... tweet | |
... | |
'This #E3 is probably already giving me more things to be excited about than the last two combined.' | |
"Maybe I'll tweet out a post #E3 press conference review video later #E32015" | |
"Haven't watched anything for #E3, but thanks to my awesome feed, I feel like I'm already caught up. XD." | |
"what's goin' on #LA? looking forward to #E3 #E3-2015 #gamerforlife #like #love #follow #followme #twitter #gamerzr…pic.twitter.com/3TGo2ODfQf" | |
"ICYI, one of the internet's best racing sim critics got an exclusive peek at Forza 6 - http://arstechnica.com/gaming/2015/06/forza-motorsport-6-getting-dark-and-wet-in-a-world-first-hands-on/\xa0… #vidcons #e3 #forza" | |
"#Fallout4 & #MGSV are, of course, my most anticipated 2015 games. But... I'm mostly hyped about more #DeusEx #MankindDivided information #E3" | |
"Thank goodness I was a bit occupied so I didn't watch the part when they showed memes at the Ubisoft conference. #UbiE3 #E3" | |
"I'm on to you. @Microsoft announces backwards compatibility for the One the day my 360 red rings. #e3 #ILLUMINATICONFIRMED" | |
"I'm going to order pizza and ready my body for Sony. Please be gentle Sony-senpai. #e3 #sony" | |
'#PlayStation\'s #e3 presser basically has to be "we\'re back compatible too" i.e. "please what will it take for you not to buy an #Xbox one?"' | |
'Best #E3 moment https://www.youtube.com/watch?v=IuH7cCBc4o4\xa0… @GhostRecon my pants are so wet right now :D #UbiE3 #UbisoftE3' | |
'I just felt actually sick watching the Mass Effect trailer. They played a note of the Vigil theme from ME1. Oh god its happening again. #e3' | |
'Video: when you sound corny like never before… #gamespot #unravel #e3 #eagames #live #YOUTUBE #ign #funny...http://tmblr.co/ZbZfos1nHcQc9\xa0' | |
'Well after a day full of orgasms thanks to #E3 imma get some sleep. Night all ' | |
'E3 had me like..\n\n#E32015 #E3 pic.twitter.com/YCWfUvaD0T' | |
'But, come on now, gotta lay off the bloomy sparks at some point, people. You guys. #E3' | |
'Did he just really say "Worst company in America" right in front of the dude\'s face? LOL\n\n#ThugLife #E3' | |
'Beware the new Viper alien. Extremely fast & uses its tongue to rope in your squad & squeeze them to death. #E3 pic.twitter.com/2EFCLLPoTZ' | |
'Assassin’s Creed Syndicate #E3 Cinematic Trailer - http://bit.ly/1GIM1GX\xa0 #AssassinsCreedSyndicate #Ubisoftpic.twitter.com/BFtjScLXmO' | |
'Sony please don’t disappoint me. Waiting for the live stream. #E3' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I do not understand very well
http://namkhoanhanai.net/nen-cat-bao-quy-dau-o-dau-uy-tin-tai-ha-noi/