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.44k stars 277 forks source link

Integration not loaded after updating to 2022.12 #1794

Closed figorr closed 1 year ago

figorr commented 1 year 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 After updating to 2022.12 the integration cannot be loaded after the restart.

To Reproduce

Expected behavior Integration loaded after the HA restart.

Screenshots

System details

Logs

Logger: homeassistant.util.package
Source: util/package.py:98 
First occurred: 09:16:33 (1 occurrences) 
Last logged: 09:16:33

Unable to install package alexapy==1.26.4: 
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f19439a0>: Failed to establish a new connection: [Errno -3] Try again')': /musllinux/ 
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f19400d0>: Failed to establish a new connection: [Errno -3] Try again')': /musllinux/ 
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f1940040>: Failed to establish a new connection: [Errno -3] Try again')': /musllinux/ 
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f19cab00>: Failed to establish a new connection: [Errno -3] Try again')': /musllinux/ 
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f18f1990>: Failed to establish a new connection: [Errno -3] Try again')': /musllinux/ 
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f17c1ea0>: Failed to establish a new connection: [Errno -3] Try again')': /simple/alexapy/ 
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f1b0b640>: Failed to establish a new connection: [Errno -3] Try again')': /simple/alexapy/ 
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f1b0b2b0>: Failed to establish a new connection: [Errno -3] Try again')': /simple/alexapy/ 
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f1b0b430>: Failed to establish a new connection: [Errno -3] Try again')': /simple/alexapy/ 
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f1b0b160>: Failed to establish a new connection: [Errno -3] Try again')': /simple/alexapy/ 
ERROR: Could not find a version that satisfies the requirement alexapy==1.26.4 (from versions: none) 
ERROR: No matching distribution found for alexapy==1.26.4 
WARNING: There was an error checking the latest version of pip. 

Additional context The integration was already updated to the latest version before updating Anyway, after seeing this error I went to HACS and I tried to redownloading the last available version. Then I restarted HA … without no luck, still is not being able to be loaded after the restart.

figorr commented 1 year ago

Just a picture of the error.

image

I tried to run "pip install alexapy==1.26.4", but I am getting pip command not found.

systanford commented 1 year ago

I had the same issue, along with bluetooth service failing to start. Rolling back to a previous back up of HA and updating again solved the issue entirely for me.

figorr commented 1 year ago

Thank you @systanford , Yesterday I tried to went back to a previous backup of HA ... 2022.11.5 and also 2022.11.4 ... without luck. I don't have any earliest backup thant those. The problem was not on that versions ... but after I restored the backup ... the problem is also there now.

It is very weird. I only have problems with two HACS integrations ... (Ecowater and Alexa Media Player). Both with identical result ... integrations cannot be loaded. :(

figorr commented 1 year ago

According to the FAQ section ... https://github.com/custom-components/alexa_media_player/wiki/FAQ#modulenotfounderror-no-module-named-alexapy

As I am running HA under virtuaI machine (Synology) I tried to run ... source /srv/homeassistant/homeassistant_venv/bin/activate as it is shown in the FAQ.

But I don't know how and where to introduce this command under a virtual machine environment in a Synology NAS. I tried through the ssh terminal of the synology, but I am getting no such file or directory.

alandtse commented 1 year ago

Your logs indicate a connection error. This is not related to the component but your network issue.

WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7fd9f19439a0>: Failed to establish a new connection: [Errno -3] Try again')': /musllinux/

There will be little we can do to resolve this for you. Please verify you have internet access to pypi.org from your HA box.

figorr commented 1 year ago

Just for the record and for anyone who has a similar issue in the future.

Finally I move the NAS to a new location … I connected it to a different network and … homeassistant was able to load the Alexa Media Player integration without any problem… so the files that the integration needs (and that were deleted or corrupted after installing homeassistant 2022.12) were downloaded and installed correctly.

Now I moved again the NAS to home … and the integration was loaded Ok.

So maybe there is a problem with the router … that is blocking something (although I didn’t change anything recently) o maybe it was a problem with the ISP.