alandtse / alexa_media_player

This is a custom component to allow control of Amazon Alexa devices in Home Assistant using the unofficial Alexa API.
Apache License 2.0
1.45k stars 278 forks source link

Failed to setup: #2524

Closed jeremeyi closed 1 week ago

jeremeyi commented 1 week ago

IMPORTANT: Please search the issues, including closed issues, and the FAQ before opening a new issue. The template is mandatory; failure to use it will result in issue closure.

Describe the bug

On rebooting HA I get "Failed to setup:" on the devices and services page. Usually a reload of the integration from there will clear it up. I uninstalled and reinstalled tonight to see if the issue would be resolved but it is still there. In my logs are: Logger: homeassistant.config_entries Source: config_entries.py:604 First occurred: 12:07:54 AM (1 occurrences) Last logged: 12:07:54 AM

Error setting up entry ****@yahoo.com - amazon.com for alexa_media 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/alexa_media/init.py", line 361, in async_setup_entry await login.login(cookies=await login.load_cookie()) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/site-packages/alexapy/alexalogin.py", line 328, in load_cookie cookies = pickle.loads(await myfile.read()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.12/http/cookies.py", line 312, in setitem raise CookieError("Invalid attribute %r" % (K,)) http.cookies.CookieError: Invalid attribute 'partitioned'

To Reproduce

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior

Screenshots

System details

Debug Logs (alexa_media & alexapy) Please provide logs.

Additional context

danielbrunt57 commented 1 week ago

File "/usr/local/lib/python3.12/http/cookies.py", line 312, in setitem raise CookieError("Invalid attribute %r" % (K,)) http.cookies.CookieError: Invalid attribute 'partitioned'

This is a 3 month old issue which has been resolved with alexapy v1.29.2 Edit the alexapyversion in "requirements" in config/custom_components/alexa_media/manifest.json:

  "requirements": ["alexapy==1.29.2", "packaging>=20.3", "wrapt>=1.14.0"],
jeremeyi commented 1 week ago

Thanks, that worked! Sorry for reposting, didn't see it when I searched.