Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Won't start on 2024.3.0 #85

Open
mcormick opened this issue Mar 13, 2024 · 2 comments · May be fixed by #86
Open

Won't start on 2024.3.0 #85

mcormick opened this issue Mar 13, 2024 · 2 comments · May be fixed by #86

Comments

@mcormick
Copy link

Error:

Logger: homeassistant.setup
Source: setup.py:296
First occurred: March 12, 2024 at 10:34:58 (1 occurrences)
Last logged: March 12, 2024 at 10:34:58

Setup failed for custom integration 'miio_yeelink': Unable to import component: No module named 'imp'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/setup.py", line 296, in _async_setup_component
    component = await integration.async_get_component()
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 894, in async_get_component
    comp = self.get_component()
           ^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 921, in get_component
    ComponentProtocol, importlib.import_module(self.pkg_path)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  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/miio_yeelink/__init__.py", line 38, in <module>
    from miio import (
  File "/usr/local/lib/python3.12/site-packages/miio/__init__.py", line 12, in <module>
    from miio.device import Device, DeviceStatus  # isort: skip
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/miio/device.py", line 13, in <module>
    from .miioprotocol import MiIOProtocol
  File "/usr/local/lib/python3.12/site-packages/miio/miioprotocol.py", line 13, in <module>
    import construct
  File "/usr/local/lib/python3.12/site-packages/construct/__init__.py", line 22, in <module>
    from construct.core import *
  File "/usr/local/lib/python3.12/site-packages/construct/core.py", line 3, in <module>
    import struct, io, binascii, itertools, collections, pickle, sys, os, tempfile, hashlib, importlib, imp
ModuleNotFoundError: No module named 'imp'

Warning:

Logger: homeassistant.components.fan
Source: helpers/deprecation.py:205
integration: fan (documentation, issues)
First occurred: March 12, 2024 at 10:34:58 (6 occurrences)
Last logged: March 12, 2024 at 10:34:58

SUPPORT_SET_SPEED was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use FanEntityFeature.SET_SPEED instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues
SUPPORT_DIRECTION was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use FanEntityFeature.DIRECTION instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues
SUPPORT_OSCILLATE was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use FanEntityFeature.OSCILLATE instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues

Warning:

Logger: homeassistant.const
Source: helpers/deprecation.py:205
First occurred: March 12, 2024 at 10:34:58 (136 occurrences)
Last logged: March 12, 2024 at 10:34:58

DATA_RATE_KIBIBYTES_PER_SECOND was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfDataRate.KIBIBYTES_PER_SECOND instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues
DATA_RATE_MEBIBYTES_PER_SECOND was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfDataRate.MEBIBYTES_PER_SECOND instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues
DATA_RATE_GIBIBYTES_PER_SECOND was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use UnitOfDataRate.GIBIBYTES_PER_SECOND instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues
ENTITY_CATEGORY_CONFIG was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use EntityCategory.CONFIG instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues
ENTITY_CATEGORY_DIAGNOSTIC was used from miio_yeelink, this is a deprecated constant which will be removed in HA Core 2025.1. Use EntityCategory.DIAGNOSTIC instead, please create a bug report at https://github.com/al-one/hass-miio-yeelink/issues
@Theliel
Copy link

Theliel commented Mar 17, 2024

For now, you need to edit manually manifest.json and change construc version to 2.10.68

Restart HA, and working fine again.

@vaReliy
Copy link

vaReliy commented Mar 20, 2024

@Theliel thanks a lot!! This solution works well for me!

chommik pushed a commit to chommik/hass-miio-yeelink that referenced this issue Apr 10, 2024
This should fix import problem mentioned in al-one#85.
Fix provided by @Theliel, testes by @vaRelly

fixes al-one#85
chommik added a commit to chommik/hass-miio-yeelink that referenced this issue Apr 10, 2024
This should fix import problem mentioned in al-one#85.
Fix provided by @Theliel, testes by @vaRelly

fixes al-one#85
chommik added a commit to chommik/hass-miio-yeelink that referenced this issue Apr 10, 2024
This should fix import problem mentioned in al-one#85.
Fix provided by @Theliel, testes by @vaReliy

fixes al-one#85
@chommik chommik linked a pull request Apr 10, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants