home-assistant / core

:house_with_garden: Open source home automation that puts local control and privacy first.
https://www.home-assistant.io
Apache License 2.0
73.45k stars 30.69k forks source link

OpenWeatherMap not starting, error message #105064

Closed IntoTheWebNet closed 7 months ago

IntoTheWebNet commented 11 months ago

The problem

Logger: homeassistant.setup Source: setup.py:215 First occurred: 11:14:27 (1 occurrences) Last logged: 11:14:27

Setup failed for openweathermap: Unable to import component: cannot import name 'resource_filename' from 'pkg_resources' (/usr/local/lib/python3.11/site-packages/pkg_resources/init.py) Traceback (most recent call last): File "/usr/src/homeassistant/homeassistant/setup.py", line 215, in _async_setup_component component = integration.get_component() ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/src/homeassistant/homeassistant/loader.py", line 816, in get_component ComponentProtocol, importlib.import_module(self.pkg_path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/importlib/init.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "", line 1204, in _gcd_import File "", line 1176, in _find_and_load File "", line 1147, in _find_and_load_unlocked File "", line 690, in _load_unlocked File "", line 940, in exec_module File "", line 241, in _call_with_frames_removed File "/usr/src/homeassistant/homeassistant/components/openweathermap/init.py", line 7, in from pyowm import OWM File "/usr/local/lib/python3.11/site-packages/pyowm/init.py", line 4, in from pyowm.owm import OWM File "/usr/local/lib/python3.11/site-packages/pyowm/owm.py", line 14, in from pyowm.commons import cityidregistry File "/usr/local/lib/python3.11/site-packages/pyowm/commons/cityidregistry.py", line 5, in from pkg_resources import resource_filename ImportError: cannot import name 'resource_filename' from 'pkg_resources' (/usr/local/lib/python3.11/site-packages/pkg_resources/init.py)

What version of Home Assistant Core has the issue?

core-2023.11.3

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

No response

Link to integration documentation on our website

No response

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

home-assistant[bot] commented 11 months ago

Hey there @fabaff, @freekode, @nzapponi, mind taking a look at this issue as it has been labeled with an integration (openweathermap) you are listed as a code owner for? Thanks!

Code owner commands Code owners of `openweathermap` 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 openweathermap` Removes the current integration label and assignees on the issue, add the integration domain after the command. - `@home-assistant add-label needs-more-information` Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue. - `@home-assistant remove-label needs-more-information` Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


openweathermap documentation openweathermap source (message by IssueLinks)

jamesbone86 commented 11 months ago

Having the same issue all of a sudden. Been working perfectly well until a few days ago. Home Assistant - Docker container.

jamesbone86 commented 11 months ago

pip install --force-reinstall -U setuptools

Worked to fix this.

issue-triage-workflows[bot] commented 8 months ago

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.