Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
52 lines (40 sloc) 1.45 KB
#!/usr/bin/python
import logging
from time import strftime
# fill me in! and take off the .bp
#logging
timestamp = strftime("%Y-%m-%d-%H:%M:%S")
logging.basicConfig(level=logging.DEBUG,
format='%(asctime)s %(name)-12s %(levelname)-8s %(message)s',
datefmt='%m-%d %H:%M:%S',
filename='logs/%s.log' % timestamp,
filemode='w')
database = 'signatures.db'
#debug mode
ch = logging.StreamHandler()
ch.setLevel(logging.INFO)
logger.addHandler(ch)
wh_url_base = 'https://wwws.whitehouse.gov/petition-tool/signatures/more/'
wh_url_id1 = '4fafe312709f037653000011' # CHANGE THIS
wh_url_num = 1
wh_url_id2 = '4fbbf03b2ee8d0a55900005f' # CHANGE THIS
#twitter junk
# The consumer keys can be found on your application's Details
# page located at https://dev.twitter.com/apps (under "OAuth settings")
consumer_key = ''
consumer_secret = ''
# The access tokens can be found on your applications's Details
# page located at https://dev.twitter.com/apps (located
# under "Your access token")
access_token = ''
access_token_secret = ''
# message properties
msg_preamble = "#OAMonday petition at %s signatures. Thanks to "
msg_postamble = "! wh.gov/6TH"
# SPECIAL FEATURE
# Perform a complete sweep?
# Will stop after full page of existing entries if False
complete_flag = False
##False if you want to suppress twitter status updates.
# used for testing and initial database population.
twitter_live_mode = False