What is the recommended way to install dependencies for custom components in a production environment?
I’m extending the functionality of an existing integration component with an ambition to contribute the adaptations to the community once I’ve verified the changes. It works in my development environment, but I’m having trouble updating the depending PyPi modules in my production environment.
What I’ve done:
I’ve cloned the home assistant core repository and modified one of the official components (growatt_server) in my GitHub repo.
I’ve also modified the underlying PyPi (GrowattServer 1.5.0) python package also in a seperate cloned GitHub repo.
I’ve updated version+requirements of growatt_server manifest.json to point at my GitHub repo instead of the PyPi (1.5.0) version:
{
"domain": "growatt_server",
"name": "Growatt",
"codeowners": [],
"config_flow": true,
"documentation": "https://www.home-assistant.io/integrations/growatt_server",
"iot_class": "cloud_polling",
"loggers": ["growattServer"],
"version": "1.6.0",
"requirements": ["growattServer @ git+https://github.com/johanzander/PyPi_GrowattServer.git@master"]
}
This works in my HA core docker development environment container.
How can I deploy this to a production environment including the dependency to my modified PyPi_GrowattServer?
The normal way to install a custom component seem to be to just copy the component into the custom_component folder.
This part works, it overrides the standard integration, but my updated growattServer from my GitHub is not fetched. There seemed to be a way by putting packages in a dept folder, but this seems deprecated.
Please advise on how to get this working.
srescio
(Simone Rescio)
October 27, 2024, 5:27pm
2
got same question, am testing a change for AMP which works in docker HA core, but seems like it does not get picked up in my main HA supervised
i tried following these steps , but restarting HA does not seem to do the job
srescio
(Simone Rescio)
October 27, 2024, 5:53pm
3
one thing I noticed is that the server restart alone does not guarantee for the manifest deps to be refreshed,
if I recompile the docker container all dep files disappear and everything gets reinstalled and downloaded anew, at that point branch files are downloaded correctly,
would like to do the same thing with supervised instance
srescio
(Simone Rescio)
October 27, 2024, 7:07pm
4
@Johan_Zander after playing a bit with the supervisor help commands, this should rebuild the container running the core
and reinstall everything
core rebuild
also these steps by @Figorr to log into the core container will allow you even more freedom to run anything in the container context:
opened 01:03PM - 10 Aug 24 UTC
**IMPORTANT: Please search the issues, including closed issues, and the [FAQ](ht… tps://github.com/alandtse/alexa_media_player/wiki/FAQ) before opening a new issue. The template is mandatory; failure to use it will result in issue closure.**
**Describe the bug**
Looks like in Homeassistant OS X64, 2024.8.0 integration Alexa Media Player in continuously asking for authentification or reauthentification.
integration version 4.12.7, amazon.com domain, 2FA enabled.
Even just after authentification no dot speaker is shown.
**To Reproduce**
1. Go to Alexa Media Player
2. Click on reconfigure and authenticate, even the auth process went fine none of my dot speakers are shown and "attention required message is appearing
Reauthenticate [[email protected] ](mailto:[email protected] ) on the [Integrations](http://192.168.68.xxx:8123/config/integrations) page. Relogin required after 0:00:01.582947 and 2 api calls.
**Expected behavior**
to stop asking for authentification and my dot speakers to appear in HAOS
**Screenshots**
attached
**System details**
Core
2024.8.0
Supervisor
2024.08.0
Operating System
12.4
Frontend
20240806.1
alexa_media (version from const.py or HA startup): Which ever is the latest updated new version (08/08/24)
alexapy (version from pip show alexapy or HA startup): Same as above
Amazon [2FA is enabled] - Yes
<img width="1113" alt="Screenshot 2024-08-10 at 15 41 12" src="https://github.com/user-attachments/assets/e1f96452-30b3-4dc5-97de-b090d9041d12">
<img width="493" alt="Screenshot 2024-08-10 at 15 33 34" src="https://github.com/user-attachments/assets/4eb9f7a9-15c4-4d24-b951-e4b7c3350665">
. :
**Logs**
Please provide [logs](https://github.com/alandtse/alexa_media_player/wiki/FAQ#how-do-i-enable-debug-logging-for-the-component).
('Login error detected; not contacting API',)
2024-08-10 15:53:41.987 WARNING (MainThread) [alexapy.helpers] alexaapi.get_bluetooth((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.009 WARNING (MainThread) [alexapy.helpers] alexaapi.get_guard_details((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.009 WARNING (MainThread) [alexapy.helpers] alexaapi.get_network_details((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.022 WARNING (MainThread) [alexapy.helpers] alexaapi.get_authentication((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.030 WARNING (MainThread) [alexapy.helpers] alexaapi.get_authentication((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.046 WARNING (MainThread) [alexapy.helpers] alexaapi.get_dnd_state((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.054 WARNING (MainThread) [alexapy.helpers] alexaapi.get_bluetooth((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.095 WARNING (MainThread) [alexapy.helpers] alexaapi.get_devices((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.226 WARNING (MainThread) [alexapy.helpers] alexaapi.get_dnd_state((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.250 WARNING (MainThread) [alexapy.helpers] alexaapi.get_authentication((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.279 WARNING (MainThread) [alexapy.helpers] alexaapi.get_device_preferences((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.298 WARNING (MainThread) [alexapy.helpers] alexaapi.get_devices((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.313 WARNING (MainThread) [alexapy.helpers] alexaapi.get_device_preferences((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
2024-08-10 15:53:42.356 WARNING (MainThread) [alexapy.helpers] alexaapi.get_device_preferences((<alexapy.alexalogin.AlexaLogin object at 0x7f4392050470>,), {}): An error occurred accessing AlexaAPI: An exception of type AlexapyLoginError occurred. Arguments:
('Login error detected; not contacting API',)
**Additional context**