core icon indicating copy to clipboard operation
core copied to clipboard

Waqi platform import error

Open Mariusthvdb opened this issue 2 years ago • 7 comments

The problem

Waqi throws error and cant be setup

What version of Home Assistant Core has the issue?

2023.6.0b0

What was the last working version of Home Assistant Core?

2023.5.x

What type of installation are you running?

Home Assistant OS

Integration causing the issue

waqi

Link to integration documentation on our website

https://rc.home-assistant.io/integrations/waqi/

Diagnostics information

No response

Example YAML snippet

- platform: waqi
    token: !secret waqi_token
    locations:
#       - Vennekenstraat, Huijbergen
#       - Station Ossendrecht, Brabant
#       - Station Moerdijk, Brabant
      - Station Woensdrecht, Brabant
#       - Zevenbergen, Brabant
#       - Klundert, Brabant
#       - Schiedamsevest, Rotterdam
#       - Groenborgerlaan, Antwerpen

Anything in the logs that might be useful for us?

Logger: homeassistant.loader
Source: components/waqi/sensor.py:10 
First occurred: 07:56:36 (1 occurrences) 
Last logged: 07:56:36

Unexpected exception importing platform homeassistant.components.waqi.sensor
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/loader.py", line 833, in get_platform
    cache[full_name] = self._import_platform(platform_name)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/loader.py", line 850, in _import_platform
    return importlib.import_module(f"{self.pkg_path}.{platform_name}")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1206, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1178, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1149, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/usr/src/homeassistant/homeassistant/components/waqi/sensor.py", line 10, in <module>
    from waqiasync import WaqiClient
  File "/usr/local/lib/python3.11/site-packages/waqiasync/__init__.py", line 12, in <module>
    class WaqiClient(object):
  File "/usr/local/lib/python3.11/site-packages/waqiasync/__init__.py", line 29, in WaqiClient
    @asyncio.coroutine
     ^^^^^^^^^^^^^^^^^
AttributeError: module 'asyncio' has no attribute 'coroutine'

Additional information

No response

Mariusthvdb avatar Jun 01 '23 05:06 Mariusthvdb

Hey there @andrey-git, mind taking a look at this issue as it has been labeled with an integration (waqi) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of waqi can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign waqi Removes the current integration label and assignees on the issue, add the integration domain after the command.

(message by CodeOwnersMention)


waqi documentation waqi source (message by IssueLinks)

home-assistant[bot] avatar Jun 01 '23 05:06 home-assistant[bot]

Ref: https://github.com/andrey-git/waqi-async/issues/4 Fix: https://github.com/andrey-git/waqi-async/pull/5

frenck avatar Jun 01 '23 06:06 frenck

Ref: andrey-git/waqi-async#4 Fix: andrey-git/waqi-async#5

Hi @frenck - does that mean this will be resolved when 2023.6 exits the beta? My apologies if I'm misunderstanding.

chicknlil avatar Jun 04 '23 16:06 chicknlil

Hi @frenck - does that mean this will be resolved when 2023.6 exits the beta? My apologies if I'm misunderstanding.

It means there is upstream fixes pending that we are awaiting, it is out of our control.

../Frenck

frenck avatar Jun 04 '23 16:06 frenck

Hi @frenck - does that mean this will be resolved when 2023.6 exits the beta? My apologies if I'm misunderstanding.

It means there is upstream fixes pending that we are awaiting, it is out of our control.

../Frenck

Thanks for letting me know! 👍

chicknlil avatar Jun 04 '23 16:06 chicknlil

Because of the current 'out of HA control ' situation it would be best to mark the integration broken in the HA docs.

The code owner has been out of touch for a very long time, no hope really this would change on short notice..

Mariusthvdb avatar Jun 04 '23 17:06 Mariusthvdb

Because of the current 'out of HA control ' situation it would be best to mark the integration broken in the HA docs.

It is a bug, we don't track bugs in our documentation. This is the right place to track those.

../Frenck

frenck avatar Jun 05 '23 07:06 frenck

I have merged the pull request and released a new version 1.1 of waqiasync

andrey-git avatar Jun 06 '23 07:06 andrey-git

Thanks @andrey-git

balloob avatar Jun 07 '23 00:06 balloob