natekspencer / hacs-pura

Home Assistant integration for Pura smart fragrance diffusers
MIT License
18 stars 1 forks source link

Unexpected Error....while setting-up #35

Closed sambeetm closed 9 months ago

sambeetm commented 9 months ago

The problem

while setting-up the integration, after inputting the user id and pw, i am getting "unexpected error". Below details are shown in the log. Can login using the app and web without any issues and see 3 Pura devices plus Pura Car.

What version of Home Assistant Core are you running?

core-2023.11.3

What was the last working version of Home Assistant Core?

No response

Diagnostics information

No response

Anything in the logs that might be useful?

.exceptions.UnknownServiceError: Unknown service: 'cognito-idp'. Valid service names are: 
2023-11-30 22:03:46.067 ERROR (MainThread) [custom_components.pura.config_flow] Unknown service: 'cognito-idp'. Valid service names are: 
Traceback (most recent call last):
  File "/config/custom_components/pura/config_flow.py", line 52, in async_pura_login
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pypura/pura.py", line 86, in authenticate
    self.get_user().authenticate(password=password)
    ^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pypura/pura.py", line 48, in get_user
    self._user = Cognito(
                 ^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/pycognito/__init__.py", line 208, in __init__
    self.client = boto3.client("cognito-idp", **boto3_client_kwargs)
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/boto3/__init__.py", line 93, in client
  File "/usr/local/lib/python3.11/site-packages/boto3/session.py", line 270, in client
    then ``use_ssl`` is ignored.
       ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/botocore/session.py", line 841, in create_client
    aws_secret_access_key=None,
             ^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/botocore/client.py", line 83, in create_client
  File "/usr/local/lib/python3.11/site-packages/botocore/client.py", line 150, in _load_service_model
    )

  File "/usr/local/lib/python3.11/site-packages/botocore/loaders.py", line 132, in _wrapper
    ``self._cache`` dictionary.
               ^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/botocore/loaders.py", line 377, in load_service_model

Additional information

No response

natekspencer commented 9 months ago

Can you validate what version of this integration you are running as well?

sambeetm commented 9 months ago

After a HA restart, the error is gone and I am able to configure the devices. Thanks!On Dec 1, 2023, at 1:31 AM, Nathan Spencer @.***> wrote: Can you validate what version of this integration you are running as well?

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>