dknowles2 / ha-pitboss

Home Assistant Custom Integration for PitBoss smokers and grills
MIT License
31 stars 4 forks source link

Integration fails to load after upgrade from 2024.6.0 to 2024.6.1 #56

Closed SomeFixItDude closed 4 months ago

SomeFixItDude commented 4 months ago

System Health details

System Information

version core-2024.6.4
installation_type Home Assistant OS
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.12.2
os_name Linux
os_version 6.6.33-haos
arch x86_64
timezone America/New_York
config_dir /config
Home Assistant Community Store GitHub API | ok -- | -- GitHub Content | ok GitHub Web | ok GitHub API Calls Remaining | 4970 Installed Version | 1.34.0 Stage | running Available Repositories | 1459 Downloaded Repositories | 8 HACS Data | ok
Home Assistant Cloud logged_in | false -- | -- can_reach_cert_server | ok can_reach_cloud_auth | ok can_reach_cloud | ok
Home Assistant Supervisor host_os | Home Assistant OS 12.4 -- | -- update_channel | stable supervisor_version | supervisor-2024.06.0 agent_version | 1.6.0 docker_version | 26.1.4 disk_total | 116.7 GB disk_used | 9.4 GB healthy | true supported | true host_connectivity | true supervisor_connectivity | true ntp_synchronized | true virtualization | board | generic-x86-64 supervisor_api | ok version_api | ok installed_addons | Studio Code Server (5.15.0), Matter Server (6.1.2), Z-Wave JS (0.6.2), ESPHome (2024.6.1), Mosquitto broker (6.4.1)
Dashboards dashboards | 3 -- | -- resources | 2 views | 8 mode | storage
Recorder oldest_recorder_run | June 17, 2024 at 12:02 PM -- | -- current_recorder_run | June 24, 2024 at 10:21 AM estimated_db_size | 225.41 MiB database_engine | sqlite database_version | 3.44.2

Checklist

Describe the issue

After upgrading from 2024.6.0 to 2024.6.1 I get the error integration failed to load. It appears to be related to climate

Reproduction steps

  1. Install update from previous release

Debug logs

Logger: homeassistant.util.loop
Source: util/loop.py:84
First occurred: 10:21:54 AM (1 occurrences)
Last logged: 10:21:54 AM

Detected blocking call to import_module inside the event loop by custom integration 'pitboss' at custom_components/pitboss/__init__.py, line 57: await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS) (offender: /usr/src/homeassistant/homeassistant/loader.py, line 1281: return importlib.import_module(f"{self.pkg_path}.{platform_name}")), please create a bug report at https://github.com/dknowles2/ha-pitboss/issues Traceback (most recent call last): File "<frozen runpy>", line 198, in _run_module_as_main File "<frozen runpy>", line 88, in _run_code File "/usr/src/homeassistant/homeassistant/__main__.py", line 223, in <module> sys.exit(main()) File "/usr/src/homeassistant/homeassistant/__main__.py", line 209, in main exit_code = runner.run(runtime_conf) File "/usr/src/homeassistant/homeassistant/runner.py", line 190, in run return loop.run_until_complete(setup_and_run_hass(runtime_config)) File "/usr/local/lib/python3.12/asyncio/base_events.py", line 672, in run_until_complete self.run_forever() File "/usr/local/lib/python3.12/asyncio/base_events.py", line 639, in run_forever self._run_once() File "/usr/local/lib/python3.12/asyncio/base_events.py", line 1988, in _run_once handle._run() File "/usr/local/lib/python3.12/asyncio/events.py", line 88, in _run self._context.run(self._callback, *self._args) File "/usr/src/homeassistant/homeassistant/config_entries.py", line 742, in async_setup_locked await self.async_setup(hass, integration=integration) File "/usr/src/homeassistant/homeassistant/config_entries.py", line 594, in async_setup result = await component.async_setup_entry(hass, self) File "/config/custom_components/pitboss/__init__.py", line 57, in async_setup_entry await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)

Logger: homeassistant.loader
Source: loader.py:1249
First occurred: 10:21:54 AM (2 occurrences)
Last logged: 10:21:54 AM

Unexpected exception importing platform custom_components.pitboss.climate
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1249, in _load_platform
    cache[full_name] = self._import_platform(platform_name)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1281, in _import_platform
    return importlib.import_module(f"{self.pkg_path}.{platform_name}")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/util/loop.py", line 131, in protected_loop_func
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/importlib/__init__.py", line 90, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 995, in exec_module
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
  File "/config/custom_components/pitboss/climate.py", line 34, in <module>
    class GrillClimate(BaseEntity, ClimateEntity):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 395, in __init__
    wrap_attr(cls, property_name)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 367, in wrap_attr
    raise TypeError(f"Can't override {attr_name} in subclass")
TypeError: Can't override _attr_max_temp in subclass

Logger: homeassistant.config_entries
Source: config_entries.py:594
First occurred: 10:21:54 AM (1 occurrences)
Last logged: 10:21:54 AM

Error setting up entry PBL-02143D8 for pitboss
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1249, in _load_platform
    cache[full_name] = self._import_platform(platform_name)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1281, in _import_platform
    return importlib.import_module(f"{self.pkg_path}.{platform_name}")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/util/loop.py", line 131, in protected_loop_func
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/importlib/__init__.py", line 90, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 995, in exec_module
  File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
  File "/config/custom_components/pitboss/climate.py", line 34, in <module>
    class GrillClimate(BaseEntity, ClimateEntity):
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 395, in __init__
    wrap_attr(cls, property_name)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 367, in wrap_attr
    raise TypeError(f"Can't override {attr_name} in subclass")
TypeError: Can't override _attr_max_temp in subclass

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 594, in async_setup
    result = await component.async_setup_entry(hass, self)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/pitboss/__init__.py", line 57, in async_setup_entry
    await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 2031, in async_forward_entry_setups
    await integration.async_get_platforms(platforms)
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1162, in async_get_platforms
    import_future.result()
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1162, in async_get_platforms
    import_future.result()
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1162, in async_get_platforms
    import_future.result()
  [Previous line repeated 2 more times]
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1150, in async_get_platforms
    platforms.update(self._load_platforms(platform_names))
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1075, in _load_platforms
    platform_name: self._load_platform(platform_name)
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 1269, in _load_platform
    raise ImportError(
ImportError: Exception importing custom_components.pitboss.climate

Diagnostics dump

No response

randompherret commented 4 months ago

Same issue for me. Reverting to 2024.5.0 got me back and running. My grill is the PB850PS2.

dknowles2 commented 4 months ago

https://github.com/dknowles2/ha-pitboss/releases/tag/2024.6.2 should fix this