Ubisys OTA Appears To Fail But Actually Succeeds
Introduction
In the world of smart home devices, Over-The-Air (OTA) updates are a crucial aspect of ensuring that devices remain secure and up-to-date with the latest features. However, sometimes these updates can appear to fail, leaving users wondering what went wrong. In this article, we'll explore a specific case where Ubisys devices seem to fail during OTA updates, but ultimately succeed.
The Issue
When attempting to update a Ubisys device using Home Assistant (HA), users may encounter error messages indicating that the update failed. These error messages can be misleading, suggesting that the update process has stalled or encountered an issue. However, as we'll discuss later, this is not necessarily the case.
Error Messages
The error messages associated with this issue can be quite alarming, with some users reporting the following:
2025-03-11 12:30:14.067 INFO (MainThread) [zigpy.device] [0xdf4b] OTA upgrade progress: (256168 / 256200): 99.9875%
2025-03-11 12:30:19.770 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [546817118496] Unexpected exception
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/zha/update.py", line 188, in async_install
await self.entity_data.entity.async_install(version=version)
File "/usr/local/lib/python3.13/site-packages/zha/application/platforms/update.py", line 301, in async_install
raise ZHAException(f"Update was not successful: {result}")
zha.exceptions.ZHAException: Update was not successful: <Status.FAILURE: 1>
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 245, in handle_call_service
response = await hass.services.async_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...<7 lines>...
)
^
File "/usr/src/homeassistant/homeassistant/core.py", line 2794, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2837, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1007, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
hass, entity, func, data, call.context
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1079, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/update/__init__.py", line 157, in async_install
await entity.async_install_with_progress(version, backup)
File "/usr/src/homeassistant/homeassistant/components/update/__init__.py", line 489, in async_install_with_progress
await self.async_install(version, backup)
File "/usr/src/homeassistant/homeassistant/components/zha/update.py", line 190, in async_install
raise HomeAssistantError(exc) from exc
homeassistant.exceptions.HomeAssistantError: Update was not successful: <Status.FAILURE: 1>
The Reality
Despite the error messages, the Ubisys device is actually installing the new image after it has been transmitted. This means that the update process is not failing, but rather, the logs and UI are not accurately reflecting the progress.
The Explanation
This issue is likely due to a cosmetic problem, where the device is not responding to the upgrade call correctly. However, the device is still able to install the new image, which is the primary goal of the update process.
The Solution
In this case, the solution is not to try and troubleshoot the issue, but rather to wait for a short period of time. After some minutes, HA will likely find the new version on the device and show the status correctly. This is because there is a series of upgrades to be done, and the device is simply taking its time to complete the process.
Conclusion
In conclusion, the Ubisys OTA update issue appears to be a cosmetic problem, where the device is not responding to the upgrade call correctly. However, the device is still able to install the new image, which is the primary goal of the update process. By waiting for a short period of time, users can ensure that the update process is completed successfully, and the device is up-to-date with the latest features.
Recommendations
- If you encounter error messages during the OTA update process, do not panic. Instead, wait for a short period of time to see if the issue resolves itself.
- Make sure that your device is properly connected to the network and that there are no issues with the power supply.
- If the issue persists, try restarting the device or the HA system to see if that resolves the issue.
Future Development
In the future, it would be beneficial for the developers of HA and Ubisys devices to work together to resolve this issue. This could involve improving the logging and UI to accurately reflect the progress of the update process, or implementing additional checks to ensure that the device is responding correctly to the upgrade call.
Conclusion
Q: What is the issue with Ubisys OTA updates?
A: The issue with Ubisys OTA updates is that they appear to fail, but actually succeed. This means that the device is installing the new image after it has been transmitted, but the logs and UI show error messages indicating that the update failed.
Q: What are the error messages associated with this issue?
A: The error messages associated with this issue can be quite alarming, with some users reporting the following:
2025-03-11 12:30:14.067 INFO (MainThread) [zigpy.device] [0xdf4b] OTA upgrade progress: (256168 / 256200): 99.9875%
2025-03-11 12:30:19.770 ERROR (MainThread) [homeassistant.components.websocket_api.http.connection] [546817118496] Unexpected exception
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/zha/update.py", line 188, in async_install
await self.entity_data.entity.async_install(version=version)
File "/usr/local/lib/python3.13/site-packages/zha/application/platforms/update.py", line 301, in async_install
raise ZHAException(f"Update was not successful: {result}")
zha.exceptions.ZHAException: Update was not successful: <Status.FAILURE: 1>
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 245, in handle_call_service
response = await hass.services.async_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...<7 lines>...
)
^
File "/usr/src/homeassistant/homeassistant/core.py", line 2794, in async_call
response_data = await coro
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/core.py", line 2837, in _execute_service
return await target(service_call)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1007, in entity_service_call
single_response = await _handle_entity_call(
^^^^^^^^^^^^^^^^^^^^^^^^^^
hass, entity, func, data, call.context
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
)
^
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 1079, in _handle_entity_call
result = await task
^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/update/__init__.py", line 157, in async_install
await entity.async_install_with_progress(version, backup)
File "/usr/src/homeassistant/homeassistant/components/update/__init__.py", line 489, in async_install_with_progress
await self.async_install(version, backup)
File "/usr/src/homeassistant/homeassistant/components/zha/update.py", line 190, in async_install
raise HomeAssistantError(exc) from exc
homeassistant.exceptions.HomeAssistantError: Update was not successful: <Status.FAILURE: 1>
Q: What is the root cause of this issue?
A: The root cause of this issue is a cosmetic problem, where the device is not responding to the upgrade call correctly. However, the device is still able to install the new image, which is the primary goal of the update process.
Q: How can I resolve this issue?
A: To resolve this issue, simply wait for a short period of time. After some minutes, HA will likely find the new version on the device and show the status correctly. This is because there is a series of upgrades to be done, and the device is simply taking its time to complete the process.
Q: What are some recommendations for resolving this issue?
A: Here are some recommendations for resolving this issue:
- If you encounter error messages during the OTA update process, do not panic. Instead, wait for a short period of time to see if the issue resolves itself.
- Make sure that your device is properly connected to the network and that there are no issues with the power supply.
- If the issue persists, try restarting the device or the HA system to see if that resolves the issue.
Q: What is the future development plan for resolving this issue?
A: In the future, it would be beneficial for the developers of HA and Ubisys devices to work together to resolve this issue. This could involve improving the logging and UI to accurately reflect the progress of the update process, or implementing additional checks to ensure that the device is responding correctly to the upgrade call.
Q: Can I prevent this issue from occurring in the future?
A: Yes, you can prevent this issue from occurring in the future by following the recommendations outlined above. Additionally, you can also try to update your device manually by using the HA web interface or the Ubisys app.
Q: What are some common mistakes that users make when trying to resolve this issue?
A: Some common mistakes that users make when trying to resolve this issue include:
- Panicking and trying to troubleshoot the issue immediately
- Not waiting for a short period of time to see if the issue resolves itself
- Not checking the device's power supply and network connection
- Not trying to update the device manually using the HA web interface or the Ubisys app
Q: How can I provide feedback to the developers of HA and Ubisys devices?
A: You can provide feedback to the developers of HA and Ubisys devices by submitting a bug report or a feature request on the HA or Ubisys website. You can also try to contact the developers directly through their support channels.