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

KeyError: 'url' #1

Closed
GrumpyMeow opened this issue Jun 7, 2024 · 6 comments
Closed

KeyError: 'url' #1

GrumpyMeow opened this issue Jun 7, 2024 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@GrumpyMeow
Copy link

Hi,
I've just installed this installer. But in the Home Assistant log i see the following error:

Logger: homeassistant.components.sensor
Bron: helpers/entity_platform.py:366
integratie: Sensor ([documentatie](https://www.home-assistant.io/integrations/sensor), [problemen](https://github.com/home-assistant/core/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+sensor%22))
Eerst voorgekomen: 17:08:52 (1 gebeurtenissen)
Laatst gelogd: 17:08:52

Error while setting up wakeword_installer platform for sensor
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 366, in _async_setup_platform
    await asyncio.shield(awaitable)
  File "/config/custom_components/wakeword_installer/sensor.py", line 18, in async_setup_entry
    repository_url = config_entry.data[CONF_URL]
                     ~~~~~~~~~~~~~~~~~^^^^^^^^^^
KeyError: 'url'

I've entered:

  • Github repository: https://github.com/fwartner/home-assistant-wakewords-collection
  • Folder: en
    I've also tried to use the git-repository-url, but that also doesn't work.
@fwartner fwartner added the bug Something isn't working label Jun 10, 2024
@fwartner fwartner self-assigned this Jun 10, 2024
@fwartner
Copy link
Owner

Thank you for your report.. Will look into it asap!

@sopelj
Copy link

sopelj commented Jun 28, 2024

It seems to be because the config flow uses CONF_REPOSITORY_URL (repository_url), but the sensor tries to access it with CONF_URL (url).

@IoSonoAndreaZ
Copy link

I did the same and the integration does not seem to work. What it is supposed to happen then?

Screenshot_20240628_114017

@sopelj
Copy link

sopelj commented Jun 28, 2024

Maybe check your logs. I also had to manually create the /share/openwakeword or it crashes with a "No such file or directory" error. After doing both, it properly copies the wake words to /share/openwakeword. However, it still does not create any actual entities in the UI.

@IoSonoAndreaZ
Copy link

TypeError: argument of type 'NoneType' is not iterable

2024-06-28 16:16:47.727 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up wakeword_installer platform for sensor

Traceback (most recent call last):

  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 366, in _async_setup_platform

    await asyncio.shield(awaitable)

  File "/config/custom_components/wakeword_installer/sensor.py", line 18, in async_setup_entry

    repository_url = config_entry.data[CONF_URL]

                     ~~~~~~~~~~~~~~~~~^^^^^^^^^^

@fwartner
Copy link
Owner

Should be fixed now :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants