feat: add BGL scraper and integrate into main scraping process; update image scraping logic

This commit is contained in:
Elmar Kresse
2025-02-09 19:33:53 +01:00
parent 010a3249cf
commit f1c9816d9e
7 changed files with 147 additions and 17 deletions

View File

@@ -15,7 +15,7 @@ def send_to_discord(property_data):
f"{property_data['subtitle']}\n"
f"**Zimmer:** {property_data['rooms']}\n"
f"**Wohnfläche:** {property_data['size']}\n"
f"**Gesamtmiete:** {property_data['rent']}\n"
f"**Miete:** {property_data['rent']}\n"
f"**Warmmiete:** {property_data['warm_rent']}\n"
f"**Verfügbar ab:** {property_data['availability']}\n"
f"**Link:** {property_data['link']}\n"
@@ -31,7 +31,7 @@ def send_to_discord(property_data):
try:
# Download the image
image_response = scrape_image.scrape_image(property_data["image_url"])
image_response = scrape_image.scrape_image(property_data["image_url"], property_data["owner"])
# Check if the image was downloaded successfully
if image_response == b"":