mbillow / ha-chargepoint

Home Assistant ChargePoint EV Charger Integration
MIT License
44 stars 6 forks source link

Cannot configure integration ‘brand’ #10

Closed TomStarren closed 1 year ago

TomStarren commented 2 years ago

When I’m adding this integration I get an error regarding ‘brand’.

D63F98BA-31D1-4464-9B02-4633C5450EE5

Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 191, in _async_refresh self.data = await self._async_update_data() File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 150, in _async_update_data return await self.update_method() File "/config/custom_components/chargepoint/init.py", line 149, in async_update_data hcrg_status: HomeChargerStatus = await hass.async_add_executor_job( File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, *self.kwargs) File "/usr/local/lib/python3.9/site-packages/python_chargepoint/client.py", line 42, in check_login return func(args, **kwargs) File "/usr/local/lib/python3.9/site-packages/python_chargepoint/client.py", line 296, in get_home_charger_status return HomeChargerStatus.from_json( File "/usr/local/lib/python3.9/site-packages/python_chargepoint/types.py", line 110, in from_json brand=json["brand"], KeyError: 'brand'

Any idea?

mbillow commented 2 years ago

Interesting, the ChargePoint API isn’t telling us the brand of your charger. What kind of charger do you have?

TomStarren commented 2 years ago

@mbillow I’ve got an Alfen Single Pro-line. 32FB22FC-A305-4FFA-A9DB-E60D549CBF37

mbillow commented 1 year ago

@TomStarren Apologies for the wait, finally had a few seconds to tackle this. Make sure your component is updated to v0.3.1 and then restart. That should fix your issue. I'll note though that you'll likely run into #6 since you aren't using Freedom Units. 😜

TomStarren commented 1 year ago

When I update the integration and re-enable it I receive this error in the HA log:

`Logger: homeassistant.util.package Source: util/package.py:98 First occurred: 23:33:36 (3 occurrences) Last logged: 23:33:38

Unable to install package python-chargepoint==1.6.1: ERROR: Could not find a version that satisfies the requirement python-chargepoint==1.6.1 (from versions: 1.0.0, 1.1.0, 1.2.0, 1.2.1, 1.2.2, 1.3.0, 1.4.0, 1.5.0, 1.6.0) ERROR: No matching distribution found for python-chargepoint==1.6.1`

HA is up2date

mbillow commented 1 year ago

Oop, forgot to actually release the module version:

Publishing python-chargepoint (1.6.1) to PyPI
 - Uploading python-chargepoint-1.6.1.tar.gz 100%
 - Uploading python_chargepoint-1.6.1-py3-none-any.whl 100%

Try it now. 🙊