-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.py
31 lines (26 loc) · 860 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
from src.otodom.otodom_scraper import scrape_otodom_listings
from src.olx.olx_scraper import scrape_olx_listings
from src.config import ScrapeConfig
def main():
# Create an Otodom-specific scrape configuration
otodom_config = ScrapeConfig(
city='krakow/krakow/krakow/stare-miasto',
min_price=2500,
max_price=3000,
min_area=40,
max_area=50,
base_url='https://www.otodom.pl/pl/wyniki/wynajem/mieszkanie/malopolskie'
)
# Create an OLX scrape configuration
olx_config = ScrapeConfig(
city='krakow',
min_price=2500,
max_price=3000,
min_area=40,
max_area=50,
base_url='https://www.olx.pl/nieruchomosci/mieszkania/wynajem',
)
scrape_otodom_listings(otodom_config)
scrape_olx_listings(olx_config)
if __name__ == "__main__":
main()