def __init__(self,username, password, consumer_key, consumer_secret, access_token, access_secret): self.launcher = Launcher(username, password, consumer_key, consumer_secret, access_token, access_secret) self.api = self.launcher.api() self.es = Es_twitter() self.list = [] self.root_uid = self.api.me() self.update_time = int(time.time())
def __init__(self, username, password): self.launcher = Launcher(username, password) self.api = self.launcher.api() self.driver = self.launcher.login() self.driver.get('https://twitter.com/i/notifications') self.es = Es_twitter() self.lis = self.driver.find_elements_by_xpath( '//li[@data-item-type="activity"]') self.list = []
def __init__(self, username, password, current_ts, consumer_key, consumer_secret, access_token, access_secret, *args): self.launcher = Launcher(username, password, consumer_key, consumer_secret, access_token, access_secret) self.api = self.launcher.api() self.es = Es_twitter() self.list = [] self.update_time = int(time.time()) try: self.uid = args[0] except Exception as e: print "no uid"
def __init__(self, username, password, current_ts, *args): self.launcher = Launcher(username, password) self.api = self.launcher.api() self.es = Es_twitter() self.update_time = current_ts self.list = [] try: self.uid = args[0] except Exception as e: print "no uid"
def __init__(self, username, password, consumer_key, consumer_secret, access_token, access_secret): self.launcher = Launcher(username, password, consumer_key, consumer_secret, access_token, access_secret) self.driver = self.launcher.login() self.es = Es_twitter() self.api = self.launcher.api() self.driver.get('https://twitter.com/i/notifications') time.sleep(2) self.lis = self.driver.find_elements_by_xpath('//li[@data-item-type="activity"]') self.list = [] self.update_time = int(time.time())
def __init__(self, username, password): self.launcher = Launcher(username, password) self.api = self.launcher.api() self.es = Es_twitter() self.list = [] self.root_uid = self.api.me()