mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
minor bug fix with solar
This commit is contained in:
parent
e410e8d9c8
commit
754644a857
1 changed files with 5 additions and 2 deletions
|
|
@ -854,18 +854,21 @@ class GoogleSolarApi:
|
|||
):
|
||||
continue
|
||||
|
||||
solar_api_client = cls(api_key=google_solar_api_key, solar_materials=solar_materials)
|
||||
|
||||
if unit["longitude"] is None or unit["latitude"] is None:
|
||||
# At this point, we've checked that solar PV is valid, and so we provide some defaults
|
||||
property_instance.set_solar_panel_configuration(
|
||||
solar_panel_configuration={
|
||||
"insights_data": None,
|
||||
"panel_performance": cls.default_panel_performance(property_instance=property_instance),
|
||||
"panel_performance": solar_api_client.default_panel_performance(
|
||||
property_instance=property_instance
|
||||
),
|
||||
"unit_share_of_energy": 1
|
||||
},
|
||||
)
|
||||
continue
|
||||
|
||||
solar_api_client = cls(api_key=google_solar_api_key, solar_materials=solar_materials)
|
||||
solar_api_client.get(
|
||||
longitude=unit["longitude"],
|
||||
latitude=unit["latitude"],
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue