KartoffelToby / better_thermostat

This custom component for Home Assistant will add crucial features to your climate-controlling TRV (Thermostatic Radiator Valves) to save you the work of creating automations to make it smart. It combines a room-temperature sensor, window/door sensors, weather forecasts, or an ambient temperature probe to decide when it should call for heat and automatically calibrate your TRVs to fix the imprecise measurements taken in the radiator's vicinity.
https://better-thermostat.org
GNU Affero General Public License v3.0
811 stars 124 forks source link

error handling request #510

Closed kuduacz closed 2 years ago

kuduacz commented 2 years ago

Prerequisites

Logger: aiohttp.server Source: custom_components/better_thermostat/utils/bridge.py:27 Integration: Better Thermostat (documentation, issues) First occurred: 07:35:31 (1 occurrences) Last logged: 07:35:31

Error handling request Traceback (most recent call last): File "/config/custom_components/better_thermostat/utils/bridge.py", line 18, in load_adapter "better_thermostat %s: uses adapter %s", self.name, self.integration AttributeError: 'OptionsFlowHandler' object has no attribute 'name'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/local/lib/python3.10/site-packages/aiohttp/web_protocol.py", line 435, in _handle_request resp = await request_handler(request) File "/usr/local/lib/python3.10/site-packages/aiohttp/web_app.py", line 504, in _handle resp = await handler(request) File "/usr/local/lib/python3.10/site-packages/aiohttp/web_middlewares.py", line 117, in impl return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/security_filter.py", line 60, in security_filter_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/forwarded.py", line 100, in forwarded_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/request_context.py", line 28, in request_context_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/ban.py", line 82, in ban_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/auth.py", line 236, in auth_middleware return await handler(request) File "/usr/src/homeassistant/homeassistant/components/http/view.py", line 136, in handle result = await result File "/usr/src/homeassistant/homeassistant/components/config/config_entries.py", line 218, in post return await super().post(request) File "/usr/src/homeassistant/homeassistant/components/http/data_validator.py", line 73, in wrapper result = await method(view, request, data, *args, **kwargs) File "/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py", line 71, in post result = await self._flow_mgr.async_init( File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 225, in async_init flow, result = await task File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 252, in _async_init result = await self._async_handle_step(flow, flow.init_step, data, init_done) File "/usr/src/homeassistant/homeassistant/data_entry_flow.py", line 367, in _async_handle_step result: FlowResult = await getattr(flow, method)(user_input) File "/config/custom_components/better_thermostat/config_flow.py", line 248, in async_step_init return await self.async_step_user() File "/config/custom_components/better_thermostat/config_flow.py", line 292, in async_step_user adapter = load_adapter(self) File "/config/custom_components/better_thermostat/utils/bridge.py", line 27, in load_adapter self.name, AttributeError: 'OptionsFlowHandler' object has no attribute 'name' ] Output from Home Assistant Developer Tools state e.g.

{
  YOUR DEVICE DIAGNOSTICS JSON OUTPUT HERE
}

Description

errors in code and addictionally "500 Internal Server Error Server got itself in trouble" when try to configure in devices

KartoffelToby commented 2 years ago

fix with beta 29