correct previous comits

This commit is contained in:
Daniel Roth 2026-06-26 11:26:28 +00:00
parent 632465f03f
commit f811b39fa1

View file

@ -23,8 +23,8 @@ from utilities.logger import setup_logger
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
# CONFIG — edit these before running # CONFIG — edit these before running
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
PORTFOLIO_ID: int = 805 PORTFOLIO_ID: int = 796
SCENARIO_ID: int = 1267 SCENARIO_ID: int = 1268
SQS_QUEUE_NAME: str = "modelling_e2e-queue-dev" SQS_QUEUE_NAME: str = "modelling_e2e-queue-dev"
# Max number of properties to process this run (cost cap). # Max number of properties to process this run (cost cap).
@ -42,8 +42,16 @@ COMPLETED_SINCE: datetime | None = datetime(
# True → Lambda runs the full pipeline but skips all DB writes (safe for testing). # True → Lambda runs the full pipeline but skips all DB writes (safe for testing).
DRY_RUN: bool = False DRY_RUN: bool = False
# True → Lambda skips the Google Solar fetch. # False → Lambda skips the Google Solar fetch (re-uses stored Solar data).
NO_SOLAR: bool = False REFETCH_SOLAR: bool = True
# False → use stored lodged EPC for properties that have one; properties with no
# stored lodged EPC are treated as EPC-less and routed to prediction (no API call).
REFETCH_EPC: bool = True
# False → use stored predicted EPC for EPC-less properties that have one; live
# prediction still runs when no stored predicted EPC exists for the property.
REPREDICT_EPC: bool = True
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
_REPO_ROOT = Path(__file__).resolve().parents[1] _REPO_ROOT = Path(__file__).resolve().parents[1]
@ -151,7 +159,8 @@ def main() -> None:
logger.info( logger.info(
f"sending {len(batches)} messages " f"sending {len(batches)} messages "
f"(portfolio={PORTFOLIO_ID}, scenario={SCENARIO_ID}, " f"(portfolio={PORTFOLIO_ID}, scenario={SCENARIO_ID}, "
f"dry_run={DRY_RUN}, no_solar={NO_SOLAR}) → {sqs_url}" f"dry_run={DRY_RUN}, refetch_solar={REFETCH_SOLAR}, "
f"refetch_epc={REFETCH_EPC}, repredict_epc={REPREDICT_EPC}) → {sqs_url}"
) )
for batch in batches: for batch in batches:
@ -162,7 +171,9 @@ def main() -> None:
"property_ids": batch, "property_ids": batch,
"portfolio_id": PORTFOLIO_ID, "portfolio_id": PORTFOLIO_ID,
"scenario_id": SCENARIO_ID, "scenario_id": SCENARIO_ID,
"no_solar": NO_SOLAR, "refetch_solar": REFETCH_SOLAR,
"refetch_epc": REFETCH_EPC,
"repredict_epc": REPREDICT_EPC,
"dry_run": DRY_RUN, "dry_run": DRY_RUN,
} }
), ),