You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After updating Home Assistant to version 2024.11.0, an error occurs in the Cloudflare Tunnel Monitor integration. The following error message appears in the logs.
Steps to Reproduce the Issue:
Updated Home Assistant to version 2024.11.0.
Restarted Home Assistant.
An error message appears in the logs related to the Cloudflare Tunnel Monitor integration.
Expected Result:
The integration works without errors and correctly monitors the Cloudflare tunnel.
Actual Result:
The integration does not work, and an AttributeError appears in the logs.
Logs:
Traceback (most recent call last):
File "/config/custom_components/cloudflare_tunnel_monitor/sensor.py", line 46, in fetch_tunnels
raise UpdateFailed(f"Error fetching Cloudflare tunnels: {response.status}, {response.reason}")
homeassistant.helpers.update_coordinator.UpdateFailed: Error fetching Cloudflare tunnels: 500, Internal Server Error
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 382, in _async_refresh
self.data = await self._async_update_data()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 279, in _async_update_data
return await self.update_method()
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/cloudflare_tunnel_monitor/sensor.py", line 197, in async_update_data
new_data = await fetch_tunnels(api_key, account_id, hass, config_entry.entry_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/cloudflare_tunnel_monitor/sensor.py", line 50, in fetch_tunnels
except async_timeout.TimeoutError:
^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'async_timeout' has no attribute 'TimeoutError'
Environment Information:
Home Assistant version: 2024.11.0
Cloudflare Tunnel Monitor integration version: 5.2.1
Operating System: Home Assistant OS 13.2
Additional Information:
It seems that in version 4.0.0 of the async_timeout module, TimeoutError has been removed. Modifying the exception handling in the sensor.py file on line 50 as follows solves the problem in my case:
Original code:
except async_timeout.TimeoutError:
Modified code:
import asyncio
...
except asyncio.TimeoutError:
Would it be possible to include this fix in the integration?
Thank you in advance for your help!
The text was updated successfully, but these errors were encountered:
Problem Description:
After updating Home Assistant to version 2024.11.0, an error occurs in the Cloudflare Tunnel Monitor integration. The following error message appears in the logs.
Steps to Reproduce the Issue:
Updated Home Assistant to version 2024.11.0.
Restarted Home Assistant.
An error message appears in the logs related to the Cloudflare Tunnel Monitor integration.
Expected Result:
The integration works without errors and correctly monitors the Cloudflare tunnel.
Actual Result:
The integration does not work, and an AttributeError appears in the logs.
Logs:
Environment Information:
Home Assistant version: 2024.11.0
Cloudflare Tunnel Monitor integration version: 5.2.1
Operating System: Home Assistant OS 13.2
Additional Information:
It seems that in version 4.0.0 of the async_timeout module, TimeoutError has been removed. Modifying the exception handling in the sensor.py file on line 50 as follows solves the problem in my case:
Original code:
Modified code:
Would it be possible to include this fix in the integration?
Thank you in advance for your help!
The text was updated successfully, but these errors were encountered: