"Failed to Setup" on restart
Ramias1 opened this issue · 1 comments
Running OS Version: Home Assistant OS 12.4
Home Assistant Core: 2024.8.1
Integration does not load after Home Assistant is restarted. The logs look like it is trying to load botocore from /usr/local/lib. That directly only has one file and a link to the same file. No subdirectories below it. Did a Home Assistant update remove or move botocore? I've tried to reinstall the S3 integration but the issue persists.
Logger: homeassistant.config_entries
Source: config_entries.py:604
First occurred: 8:10:14 PM (1 occurrences)
Last logged: 8:10:14 PM
Error setting up entry Personal AWS for s3
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 604, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/s3/__init__.py", line 248, in async_setup_entry
client = await hass.async_add_executor_job(boto_client, aws_config)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/s3/__init__.py", line 246, in boto_client
return boto3.client("s3", **aws_config) # Will not raise error.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/boto3/__init__.py", line 92, in client
return _get_default_session().client(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/boto3/session.py", line 299, in client
region_name=region_name,
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/botocore/session.py", line 950, in create_client
raise PartialCredentialsError(
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/botocore/client.py", line 112, in create_client
self._config_store = config_store
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/botocore/client.py", line 168, in _create_client_class
scoped_config,
File "/usr/local/lib/python3.12/site-packages/botocore/hooks.py", line 412, in emit
return self._emitter.emit(aliased_event_name, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/botocore/hooks.py", line 256, in emit
return self._emit(event_name, kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/botocore/hooks.py", line 239, in _emit
response = handler(**kwargs)
^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/boto3/utils.py", line 65, in _handler
module = import_module(module)
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.12/site-packages/boto3/utils.py", line 56, in import_module
__import__(name)
File "/usr/local/lib/python3.12/site-packages/boto3/s3/inject.py", line 18, in <module>
from boto3.s3.transfer import (
File "/usr/local/lib/python3.12/site-packages/boto3/s3/transfer.py", line 135, in <module>
from s3transfer.futures import NonThreadedExecutor
File "/usr/local/lib/python3.12/site-packages/s3transfer/futures.py", line 22, in <module>
from s3transfer.utils import FunctionContainer, TaskSemaphore
File "/usr/local/lib/python3.12/site-packages/s3transfer/utils.py", line 30, in <module>
from botocore.utils import is_s3express_bucket
ImportError: cannot import name 'is_s3express_bucket' from 'botocore.utils' (/usr/local/lib/python3.12/site-packages/botocore/utils.py)
Totally different plugin, but Rinnai is throwing a similar botocore3 error message:
Detected blocking call to listdir with args ('/usr/local/lib/python3.12/site-packages/botocore/data',) inside the event loop by custom integration 'rinnai' at custom_components/rinnai/__init__.py, line 49: hass.data[DOMAIN][entry.entry_id][CLIENT] = client = await async_get_api( (offender: /usr/local/lib/python3.12/site-packages/botocore/loaders.py, line 306: d), please report it to the author of the 'rinnai' custom integration For developers, please see https://developers.home-assistant.io/docs/asyncio_blocking_operations/#listdir 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 674, in run_until_complete self.run_forever() File "/usr/local/lib/python3.12/asyncio/base_events.py", line 641, in run_forever self._run_once() File "/usr/local/lib/python3.12/asyncio/base_events.py", line 1990, 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 752, in async_setup_locked await self.async_setup(hass, integration=integration) File "/usr/src/homeassistant/homeassistant/config_entries.py", line 604, in async_setup result = await component.async_setup_entry(hass, self) File "/config/custom_components/rinnai/__init__.py", line 49, in async_setup_entry hass.data[DOMAIN][entry.entry_id][CLIENT] = client = await async_get_api(