Commit graph

761 commits

Author SHA1 Message Date
Daniel Roth
198d2afdb1 Merge branch 'main' into feature/handle-new-magicplan-response-structure 2026-06-05 14:35:56 +00:00
Daniel Roth
b3b4ae2191 Convert Door.width_mm to store actual millimetres (multiply size.x by 1000)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-05 13:30:54 +00:00
Jun-te Kim
b07db1ef6b property override 2026-06-05 12:18:13 +00:00
Daniel Roth
ebd6f1623f Merge branch 'main' into feature/handle-new-magicplan-response-structure 2026-06-05 10:16:14 +00:00
Daniel Roth
761962e991 add ECO_SHAREPOINT_ID env var 2026-06-04 15:40:26 +00:00
Daniel Roth
6bcb695771 rename mcs_certificate to mcs_compliance_certificate to match existing db enum value 2026-06-04 15:40:26 +00:00
Daniel Roth
1af1d4a82c MCS cert identified by evidence_category in get_core_file_type 🟥 2026-06-04 15:40:25 +00:00
Daniel Roth
098f60ecfd Upload other files to S3 when get_other_files is True 🟥 2026-06-04 15:40:25 +00:00
Jun-te Kim
384e3da92a
Merge pull request #1172 from Hestia-Homes/feature/landlord_data
Feature/landlord data
2026-06-04 16:14:39 +01:00
Jun-te Kim
dfd05ba28b tests files 2026-06-04 11:47:42 +00:00
Daniel Roth
df0c8f69b1 Merge branch 'main' into feature/handle-new-magicplan-response-structure 2026-06-04 10:52:32 +00:00
Daniel Roth
eb72b0223f add ECO_SHAREPOINT_ID env var 2026-06-04 09:11:08 +00:00
Daniel Roth
174ef26075 refactor magicplan in ddd structure 2026-06-03 17:20:20 +00:00
Daniel Roth
19e40ff049 rename mcs_certificate to mcs_compliance_certificate to match existing db enum value 2026-06-03 09:00:01 +00:00
Daniel Roth
ca224515f9 MCS cert identified by evidence_category in get_core_file_type 🟥 2026-06-02 14:20:35 +00:00
Daniel Roth
1a1f9f2e6a Upload other files to S3 when get_other_files is True 🟥 2026-06-02 09:35:12 +00:00
Khalim Conn-Kowlessar
559616d3bb feat(epc): EPC persistence round-trip fidelity + JSONB code columns (Slice 1 #1129)
Relocate EpcPropertyModel + child tables from the dying backend/ tree to
infrastructure/postgres/epc_property_table.py (re-export shim keeps
documents_parser working). Add EpcRepository port + EpcPostgresRepository with
a full reverse mapper (epc_property tables -> EpcPropertyData).

Round-trip test surfaced two fidelity gaps:
 1. Union[int,str] SAP code fields were str()-coerced on save, losing the int
    (API) vs str (Site Notes) distinction. Now stored as JSONB (type-preserving).
 2. The schema was a partial projection. Closed the cheap gaps on the model
    (heating shower/bath counts, roof_construction_type, curtain_wall_age,
    addendum, mechanical_vent_duct_insulation_level, SAP 10.2 §2 ventilation
    fields + a ventilation_present flag). Structural gaps tracked as follow-ups;
    renewable_heat_incentive (P0, #1137) excluded from the assertion until landed.

Round-trip passes for RdSAP-Schema-21.0.0 and 21.0.1; pyright strict clean.
Migration inventory for the DB: docs/migrations/epc-property-round-trip-fidelity.md

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-01 16:28:48 +00:00
Jun-te Kim
d5ac70947d booking status 2026-06-01 16:28:47 +00:00
Jun-te Kim
b72a0c2be4 hubspot projects data is scraped 2026-06-01 16:28:47 +00:00
Jun-te Kim
99614820b9 made landlord overrides sqs 2026-05-29 10:41:46 +00:00
Jun-te Kim
0a99c92eb4 added batch description and nonfunded measures 2026-05-27 10:30:19 +00:00
Khalim Conn-Kowlessar
87b6045c97 fixed merge conflicts from main 2026-05-26 11:21:09 +00:00
Khalim Conn-Kowlessar
883028c89e P6.1 follow-on: unbox BuildingPartIdentifier at backend boundaries
Threads the strict BuildingPartIdentifier type (introduced in a8b443f6)
through the two remaining backend touchpoints:

- EpcBuildingPartModel.from_*: SQLModel column expects a string, so
  unbox the enum with .identifier.value before binding to the DB.
- documents_parser end-to-end tests: swap bare-string equality
  ("main" / "extension_1") for identity checks against the enum
  members (BuildingPartIdentifier.MAIN / EXTENSION_1).

Documents_parser test pack passes (105/105). No dedicated SQLModel test
covers EpcBuildingPartModel.from_*; the .value line is exercised
transitively via db_writer.py / local_runner.py in production.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-20 09:58:23 +00:00
Daniel Roth
dc3543ac5f Coordination Hub fallback stores correct file_source in DB 🟥 2026-05-19 11:07:41 +00:00
Daniel Roth
4cd59768c3 Wire coordination account fallback into config and handler, remove token-refresh retry 🟩 2026-05-18 09:22:32 +00:00
Khalim Conn-Kowlessar
0ffda529ec slice 15a: add wall/floor/roof + demand scalar features for retrofit simulation
15 new features wired through schema -> domain -> mapper -> transform:

Main Dwelling fabric (11):
  - wall_insulation_type, wall_insulation_thickness_mm, wall_dry_lined,
    wall_thickness_mm, party_wall_construction
  - roof_insulation_location, roof_insulation_thickness_mm
  - floor_construction, floor_insulation, floor_insulation_thickness_mm,
    floor_heat_loss

Dwelling-level scalars (4):
  - multiple_glazed_proportion, number_baths, number_baths_wwhrs,
    extract_fans_count

Thickness strings like '50mm'/'NI'/'ND' parsed via _parse_thickness_mm; NI
(no insulation) lands as 0mm so the model sees the physical zero rather than
a missing value. Categorical sentinels ('NA'/'NI'/'ND') become None.

Also fixed long-standing typo `multiple_glazed_propertion` -> `_proportion`
in domain dataclass + its lone DB-model usage.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-16 22:08:27 +00:00
Daniel Roth
c98fc8452f
Merge pull request #1086 from Hestia-Homes/feature/pashub-additional-files
Fetch coordination and design documents from pashub
2026-05-14 11:59:43 +01:00
Daniel Roth
cc6b64ee2b
Merge pull request #1080 from Hestia-Homes/feature/magicplan_uploaded_file_id
Include uploaded file ID on MagicPlan plan
2026-05-14 10:23:33 +01:00
Daniel Roth
5ff740d192 Merge branch 'main' into feature/pashub-additional-files 2026-05-13 15:27:04 +00:00
Jun-te Kim
27b5602608 remove pandas 2026-05-13 15:08:06 +00:00
Jun-te Kim
51460d1cd3 route at th ebeginnign 2026-05-13 14:47:24 +00:00
Jun-te Kim
54864bf102 resolve merge conflict 2026-05-13 14:22:04 +00:00
Daniel Roth
e315966565 add coordination and design document types to enums 2026-05-13 12:29:25 +00:00
Daniel Roth
265be9849b Store uploaded_file_id on magic_plan_plan row 🟥 2026-05-13 10:50:28 +00:00
Jun-te Kim
3bcb94f9e5 Merge branch 'main' into feature/integrate_new_epc_with_historical_epc 2026-05-13 08:38:50 +00:00
Jun-te Kim
09dbfe2106 fix dependency issue 2026-05-12 17:03:16 +00:00
Jun-te Kim
e458f0a2b7 task and sub tasks imrpvoed 2026-05-12 16:24:11 +00:00
Jun-te Kim
35d191c70e merged from main and resolved pytest.ini confict 2026-05-12 12:54:28 +00:00
Jun-te Kim
6504785e7c merged from main 2026-05-11 12:30:29 +00:00
Daniel Roth
6fd95d20af Merge branch 'main' into feature/magicplan-trigger 2026-05-11 09:06:47 +00:00
Jun-te Kim
c53d8b2a33 basic end up check 2026-05-10 21:07:16 +00:00
Daniel Roth
7c9cb5b161 Upload gzip-compressed MagicPlan JSON to S3 🟥 2026-05-08 14:14:42 +00:00
Jun-te Kim
8b6a572223 Merge branch 'feature/claude_skills_in_devcontainer' into feature/etl_process_for_old_csv 2026-05-08 13:09:19 +00:00
Daniel Roth
489b0ba30e Add MagicPlan SQS trigger to HubSpot orchestrator 🟥 2026-05-08 13:05:38 +00:00
Daniel Roth
f56dba4ad1 use pytest-postgresql in db tests instead of mocking and checking sql strings 2026-05-08 10:13:44 +00:00
Jun-te Kim
4f45eeb3e9 save 2026-05-07 15:55:44 +00:00
Daniel Roth
6b29086a1e typing and renaming 🟪 2026-05-07 13:26:49 +00:00
Daniel Roth
2f8e08a676 save_plan persisting domain Plan to magic_plan_* tables 🟩 2026-05-07 13:09:09 +00:00
Daniel Roth
5ec0fa5d04 save_plan persisting domain Plan to magic_plan_* tables 🟥 2026-05-07 13:01:04 +00:00
Daniel Roth
7ff7e90307 SQLModel ORM layer for magic_plan_plan/floor/room/window/door tables 🟩 2026-05-07 12:56:12 +00:00