core: SynologyDSMAPIErrorException if no cameras starting 0.116.0
The problem
After updating to HA 0.116.0, the Synology DSM integration no longer works. I was using the integration for monitoring the disks and volumes on the NAS. I receive the following error (note, I do not use SurveillanceStation) ad none of the sensors work anymore :
2020-10-07 19:36:26 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry 192.168.1.2 for synology_dsm
Environment
- Home Assistant Core release with the issue: 0.116.0
- Last working Home Assistant Core release (if known): 0.115.6
- Operating environment (OS/Container/Supervised/Core): hassio
- Integration causing this issue: synology_dsm
- Link to integration documentation on our website: https://www.home-assistant.io/integrations/synology_dsm/
Problem-relevant configuration.yaml
Note, Iām using the UI to do the setup, not yaml.
synology_dsm:
- host: IP_ADDRESS_OR_HOSTNAME_OF_SYNOLOGY_NAS
username: YOUR_USERNAME
password: YOUR_PASSWORD
Traceback/Error logs
2020-10-07 19:36:26 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry 192.168.1.2 for synology_dsm
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 231, in async_setup
result = await component.async_setup_entry(hass, self) # type: ignore
File "/usr/src/homeassistant/homeassistant/components/synology_dsm/__init__.py", line 165, in async_setup_entry
await api.async_setup()
File "/usr/src/homeassistant/homeassistant/components/synology_dsm/__init__.py", line 267, in async_setup
await self.async_update()
File "/usr/src/homeassistant/homeassistant/components/synology_dsm/__init__.py", line 358, in async_update
await self._hass.async_add_executor_job(self.dsm.update, self._with_information)
File "/usr/local/lib/python3.8/concurrent/futures/thread.py", line 57, in run
result = self.fn(*self.args, **self.kwargs)
File "/usr/local/lib/python3.8/site-packages/synology_dsm/synology_dsm.py", line 326, in update
self._surveillance.update()
File "/usr/local/lib/python3.8/site-packages/synology_dsm/api/surveillance_station/__init__.py", line 39, in update
live_view_data = self._dsm.get(
File "/usr/local/lib/python3.8/site-packages/synology_dsm/synology_dsm.py", line 186, in get
return self._request("GET", api, method, params, **kwargs)
File "/usr/local/lib/python3.8/site-packages/synology_dsm/synology_dsm.py", line 246, in _request
raise SynologyDSMAPIErrorException(
synology_dsm.exceptions.SynologyDSMAPIErrorException: {'api': 'SYNO.SurveillanceStation.Camera', 'code': 401, 'reason': 'Invalid parameter', 'details': None}
Additional information
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 1
- Comments: 25 (7 by maintainers)
Oh, we added checks if Surveillance Station was installed ā¦
So apparently it misses some. Will do.
yeah, maybe it doesnt like surveillance installed with no cameras š