From 13076b28fb70394effb34168b616aa7edcacfe39 Mon Sep 17 00:00:00 2001 From: Peter Dudfield <34686298+peterdudfield@users.noreply.github.com> Date: Sat, 26 Oct 2024 20:25:08 +0100 Subject: [PATCH] Update victron.py (#213) * Update victron.py * Update victron.py --- quartz_solar_forecast/inverters/victron.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/quartz_solar_forecast/inverters/victron.py b/quartz_solar_forecast/inverters/victron.py index 76709e8..3414f13 100644 --- a/quartz_solar_forecast/inverters/victron.py +++ b/quartz_solar_forecast/inverters/victron.py @@ -5,8 +5,10 @@ from quartz_solar_forecast.inverters.inverter import AbstractInverter from pydantic import Field from pydantic_settings import BaseSettings, SettingsConfigDict -from ocf_vrmapi.vrm import VRM_API - +try: + from ocf_vrmapi.vrm import VRM_API +except: + print("Tried to import ocf_vrmapi but couldnt, Victron Inverter functions won't work") class VictronSettings(BaseSettings): model_config = SettingsConfigDict(env_file='.env', extra='ignore')