biweeklybudget.screenscraper module¶
-
class
biweeklybudget.screenscraper.
ScreenScraper
(savedir='./', screenshot=False)[source]¶ Bases:
object
Base class for screen-scraping bank/financial websites.
Load cookies from a JSON cookie file on disk. This file is not the format used natively by PhantomJS, but rather the JSON-serialized representation of the dict returned by
selenium.webdriver.remote.webdriver.WebDriver.get_cookies()
.Cookies are loaded via
selenium.webdriver.remote.webdriver.WebDriver.add_cookie()
Parameters: cookie_file (str) – path to the cookie file on disk
Save cookies to a JSON cookie file on disk. This file is not the format used natively by PhantomJS, but rather the JSON-serialized representation of the dict returned by
selenium.webdriver.remote.webdriver.WebDriver.get_cookies()
.Parameters: cookie_file (str) – path to the cookie file on disk
-
wait_for_ajax_load
(timeout=20)[source]¶ Function to wait for an ajax event to finish and trigger page load, like the Janrain login form.
Pieced together from http://stackoverflow.com/a/15791319
timeout is in seconds