diff --git a/backend/SearchEpc.py b/backend/SearchEpc.py index f1cda010..238ae465 100644 --- a/backend/SearchEpc.py +++ b/backend/SearchEpc.py @@ -143,7 +143,6 @@ class SearchEpc: if len(uprns) == 1: return rows - logger.error("Multiple UPRNS found - we should use an alternate method of searching - TODO") if property_type is not None: # We can do a filter on the property type rows_filtered = [r for r in rows if r["property-type"] == property_type] diff --git a/etl/eligibility/ha_15_32/ha25_app.py b/etl/eligibility/ha_15_32/ha25_app.py index b2465913..07470b51 100644 --- a/etl/eligibility/ha_15_32/ha25_app.py +++ b/etl/eligibility/ha_15_32/ha25_app.py @@ -292,7 +292,7 @@ def get_epc_data(data, cleaned, cleaning_data, created_at): nodata.append(property_meta) continue - newest_epc, older_epcs, full_sap_epc = searcher.retrieve(address=property_meta["Address"]) + newest_epc, older_epcs, full_sap_epc = searcher.retrieve(address=property_meta["T1_Address"]) # We also want to get the penultimate epc penultimate_epc, _ = searcher.filter_newest_epc(older_epcs) if not penultimate_epc: @@ -336,8 +336,8 @@ def get_epc_data(data, cleaned, cleaning_data, created_at): { "row_id": property_meta["row_id"], "uprn": eligibility.epc["uprn"], - "Address": property_meta["Address"], - "Postcode": property_meta["Postcode"], + "Address": property_meta["T1_Address"], + "Postcode": property_meta["postcode"], "property_type": eligibility.epc["property-type"], "gbis_eligible": eligibility.gbis_warmfront, "eco4_eligible": eligibility.eco4_warmfront["eligible"],