Questions tagged [python-twitter]

A Python wrapper around the Twitter API

This library provides a pure Python interface for the Twitter API.

Twitter provides a service that allows people to connect via the web, IM, and SMS. Twitter exposes a web services API and this library is intended to make it even easier for Python programmers to use.

151 questions
1
vote
2 answers

python-twitter in google app engine

I am trying to use python-twitter api in GAE. I need to import Oauth2 and httplib2. Here is how I did For OAuth2, I downloaded github.com/simplegeo/python-oauth2/tree/master/oauth2. For HTTPLib2, I dowloaded code.google.com/p/httplib2/wiki/Install…
John
  • 3,888
  • 11
  • 46
  • 84
1
vote
1 answer

python-twitter retrieving all followers

I'm using the python-twitter library and while I can get the code to retrieve a 'set' of results, apparently in the first 'page' ... I for the life of me can't find the right code to get a set of ALL the followers for a specific account/handle. I'm…
user1944655
  • 13
  • 1
  • 3
1
vote
2 answers

Python script that gets my latest tweet stopped working on my server

Consider the following code: import twitter api = twitter.Api() most_recent_status = api.GetUserTimeline('nemesisdesign')[0].text On my server (nemesisdesign.net) stopped working a few days ago. If I try the same code from my own machine it works…
nemesisdesign
  • 8,159
  • 12
  • 58
  • 97
1
vote
0 answers

List Class in Python-Twitter

Despite a day's searching and trying I cannot get around the List Class of the python-twitter module. The aim of the game is very simple, I want to retrieve all the followers (my students) I have previously grouped into a Twitter list called…
jrichalot
  • 59
  • 1
  • 7
1
vote
2 answers

Searching and extracting top retweets using tweepy

I need to extract the top retweets for a given search tag.For that purpose ive done this search = [] page = 1 while(1): tweets = api.search(tag,page = page) for tweet in tweets: search.append(tweet) page = page + 1 and then from…
Manoj
  • 961
  • 4
  • 11
  • 37
0
votes
1 answer

Create URLs for different data frames

I have a data frame that I split into different data frames of size 100 (to be able to make Python able to process it). Therefore, I get different data frames (df1 to df..). For all those data frames, I want to create an URL as shown below. When I…
0
votes
1 answer

Apply the code for smaller batches in the data set sequentially

I have data set of retrieved tweets via the Twitter streaming API. However, I regularly want to be updated about how the public metrics change. Therefore, I wrote a code to request those public metrics: def create_url(): tweet_fields =…
0
votes
1 answer

How to create a loop for changing data frame names

I have several data frames and for all of them, I want to carry out the same procedure. As an example, for one data frame (df1), the code looks the following: def create_url(): df_id = (str(str((df1['id'].tolist()))[1:-1])).replace(" ", "") …
0
votes
1 answer

Request status update Twitter stream data

I retrieved Twitter data via the streaming API on Python, however, I am also interested in how the public metrics evolve during the time. As a result, I would like to request on a daily basis the metrics. Unfortunately, the API for the status update…
0
votes
1 answer

I have a problem with os module in python

I've recently had a problem with (i think) the os module in python: Traceback (most recent call last): File "main.py", line 9, in api = getApi(os.environ['consumer_key'], os.environ['consumer_secret'], os.environ['access_token_key'],…
Marcucus _
  • 88
  • 10
0
votes
2 answers

location of twitter.py file (python-twitter library) in Mac OS X 10.6.7 with Python 2.6.7

I have python 2.6.7 installed in my mac (/usr/local/bin/python). Previously, I installed python-twitter library. I follow these steps when I installed it: tar -xvf python-twitter-0.8.3.tar.gz cd python-twitter-0.8.3 python setup.py build python…
nero
  • 64
  • 1
  • 8
0
votes
1 answer

Can't authenticate Twitter credentials using python-twitter module

I'm trying to use the python-twitter to eventually set up a twitter bot. In IDLE, I've import twitter api = twitter.Api(consumer_key=['xxxx '], consumer_secret=['xxx'], access_token_key=['x-xxx'], …
booms
  • 23
  • 5
0
votes
0 answers

How to resolve ModuleNotFoundError: No module named 'twitter'

I have twitter package installed as the result of conda list | grep twitter is: python-twitter 3.5 py_0 conda-forge twitter 1.18.0 pypi_0 pypi But if I try to import twitter in my jupyter notebook using import twitter it gives an…
nkhl
  • 140
  • 2
  • 13
0
votes
3 answers

How to get 3200 tweets from a new Twitter's API and what is GetOldTweets3 alternative?

As it is clear GetOldTweets3 is a python library for accessing old tweets which is not easily feasible with libraries like Tweepy. But recently, there is an unsolved issue with it due to the new Twitter API:…
ECub Devs
  • 165
  • 3
  • 10
0
votes
1 answer

Retrieve tweets of a twitter account starting from certain date to current date

I want to write a script that retrieve the tweets from a twitter account. Here is the scenario that I would like to achieve: my script should be able to retrieve all tweets of a user starting from certain date (can be set by the user to any date as…
nero
  • 64
  • 1
  • 8