add apprise and send notification when refreshing listings

This commit is contained in:
Viktor Barzin 2025-07-25 21:32:06 +00:00
parent ce386e748d
commit 762408e054
No known key found for this signature in database
GPG key ID: 4056458DBDBF8863
6 changed files with 105 additions and 6 deletions

View file

@ -77,7 +77,7 @@ class ListingRepository:
if query_parameters.furnish_types:
query = query.where(model.furnish_type.in_(query_parameters.furnish_types))
if (
isinstance(model, BuyListing)
isinstance(model, RentListing)
and query_parameters.let_date_available_from is not None
):
query = query.where(
@ -120,9 +120,6 @@ class ListingRepository:
try:
model_listing = await self._get_concrete_listing(listing)
except Exception as e: # WHY SO MANY ERORRS??
import ipdb
ipdb.set_trace()
# If for whatever reason we cannot add listing, ignore and retry
print(f"Error converting listing {listing.identifier}: {e}")
failed_to_upsert.append(listing)