Merge
This commit is contained in:
parent
8c00ece7bd
commit
b06fe841ae
1 changed files with 10 additions and 2 deletions
12
setup.py
12
setup.py
|
@ -65,13 +65,21 @@ db.closeConnection()
|
|||
|
||||
config.add_section("Twitter")
|
||||
|
||||
cke = "V6ekVFYtavi6IvRFLS0dHifSh"
|
||||
cse = "U2duSfBtW0Z8UQFoJyARf3jU80gdQ44EEqWqC82ebuGbIPN3t7"
|
||||
print('''We are going to need a consumer key and consumer secret for accessing Twitter.
|
||||
If you don't have this yet, go to apps.twitter.com and create a new application. This
|
||||
application will need read/write access as well as access to direct messages.''')
|
||||
|
||||
cke = input("Consumer key: ")
|
||||
cse = input("Consumer secret: ")
|
||||
|
||||
config.set("Twitter", "cke", cke)
|
||||
config.set("Twitter", "cse", cse)
|
||||
|
||||
auth = tweepy.OAuthHandler(cke, cse)
|
||||
try:
|
||||
auth = tweepy.OAuthHandler(cke, cse)
|
||||
except tweepy.TweepError:
|
||||
print("Failed to authenticate with Twitter. Please check your consumer key and secret.")
|
||||
|
||||
try:
|
||||
authurl = auth.get_authorization_url()
|
||||
|
|
Loading…
Reference in a new issue