core: Somfy API integration bug: TypeError: unsupported operand type(s) for -: 'int' and 'str'
Home Assistant release with the issue: 0.103.2
Last working Home Assistant release (if known): 0.102.x (9 dec)
Maybe since this commit was in the release: https://github.com/home-assistant/home-assistant/pull/29675 or maybe Somfy changed something on their end but can’t find any release notes.
Operating environment (Hass.io/Docker/Windows/etc.): Docker
Integration: https://www.home-assistant.io/integrations/somfy/
Description of problem:
Shutter component not working anymore (roller_shutter_positionable_stateful_generic)
Screen does work (exterior_blind_positionable_stateful_generic)
Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):
somfy:
client_id: xxx
client_secret: xxx
Traceback (if applicable):
2019-12-19 12:45:38 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 286, in async_update_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 327, in _async_write_ha_state
attr.update(self.state_attributes or {})
File "/usr/src/homeassistant/homeassistant/components/cover/__init__.py", line 198, in state_attributes
current = self.current_cover_position
File "/usr/src/homeassistant/homeassistant/components/somfy/cover.py", line 69, in current_cover_position
position = 100 - self.cover.get_position()
TypeError: unsupported operand type(s) for -: 'int' and 'str'
Additional information:
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 34 (13 by maintainers)
I got an answer from the Somfy support. They will fix this quickly!