diff --git a/homeharvest/core/scrapers/__init__.py b/homeharvest/core/scrapers/__init__.py index 2bdf972..2f14381 100644 --- a/homeharvest/core/scrapers/__init__.py +++ b/homeharvest/core/scrapers/__init__.py @@ -16,7 +16,14 @@ class Scraper: self.location = scraper_input.location self.listing_type = scraper_input.listing_type - self.session = requests.Session(proxies=scraper_input.proxy) + self.session = requests.Session() + if scraper_input.proxy: + proxy_url = scraper_input.proxy + proxies = { + "http": proxy_url, + "https": proxy_url + } + self.session.proxies.update(proxies) self.listing_type = scraper_input.listing_type self.site_name = scraper_input.site_name diff --git a/pyproject.toml b/pyproject.toml index e406c31..d5f392a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "homeharvest" -version = "0.2.4" +version = "0.2.5" description = "Real estate scraping library supporting Zillow, Realtor.com & Redfin." authors = ["Zachary Hampton ", "Cullen Watson "] homepage = "https://github.com/ZacharyHampton/HomeHarvest"