Hi,
I have been running this version of the HACs integration for AmpliPi. I noticed in the v0.4.2 release notes that the integration has had some love, but it is now to be found at;
https://github.com/micro-nova/hacs_amplipi
So I removed Brian’s version completely, deleted all my entities, and the HACs integration etc.
But when trying to re-install the new mico-nova version I was not getting any auto-discovery happening. So I tried to manually add a device, entering the IP address of my AmpliPi in the first box, and 80
in the second box (neither having labels) and it came up saying the device had been successfully installed.
However looking in my device list there was an entry for the AmpliPi but it was saying there was an error;
homeassistant_app.1.x4d476o5470w@nuc01 | 2024-08-09 13:56:03.582 WARNING (MainThread) [custom_components.amplipi.config_flow] New Amplipi by user
homeassistant_app.1.x4d476o5470w@nuc01 | 2024-08-09 13:56:03.750 WARNING (MainThread) [homeassistant.util.loop] Detected blocking call to import_module with args ('custom_components.amplipi.media_player',) inside the event loop by custom integration 'amplipi' at custom_components/amplipi/__init__.py, line 33: await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS) (offender: /usr/src/homeassistant/homeassistant/loader.py, line 1296: return importlib.import_module(f"{self.pkg_path}.{platform_name}")), please report it to the author of the 'amplipi' custom integration
homeassistant_app.1.x4d476o5470w@nuc01 | For developers, please see https://developers.home-assistant.io/docs/asyncio_blocking_operations/#import_module
homeassistant_app.1.x4d476o5470w@nuc01 | Traceback (most recent call last):
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen runpy>", line 198, in _run_module_as_main
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen runpy>", line 88, in _run_code
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/__main__.py", line 223, in <module>
homeassistant_app.1.x4d476o5470w@nuc01 | sys.exit(main())
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/__main__.py", line 209, in main
homeassistant_app.1.x4d476o5470w@nuc01 | exit_code = runner.run(runtime_conf)
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/runner.py", line 190, in run
homeassistant_app.1.x4d476o5470w@nuc01 | return loop.run_until_complete(setup_and_run_hass(runtime_config))
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/local/lib/python3.12/asyncio/base_events.py", line 674, in run_until_complete
homeassistant_app.1.x4d476o5470w@nuc01 | self.run_forever()
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/local/lib/python3.12/asyncio/base_events.py", line 641, in run_forever
homeassistant_app.1.x4d476o5470w@nuc01 | self._run_once()
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/local/lib/python3.12/asyncio/base_events.py", line 1990, in _run_once
homeassistant_app.1.x4d476o5470w@nuc01 | handle._run()
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/local/lib/python3.12/asyncio/events.py", line 88, in _run
homeassistant_app.1.x4d476o5470w@nuc01 | self._context.run(self._callback, *self._args)
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/config_entries.py", line 752, in async_setup_locked
homeassistant_app.1.x4d476o5470w@nuc01 | await self.async_setup(hass, integration=integration)
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/config_entries.py", line 604, in async_setup
homeassistant_app.1.x4d476o5470w@nuc01 | result = await component.async_setup_entry(hass, self)
homeassistant_app.1.x4d476o5470w@nuc01 | File "/config/custom_components/amplipi/__init__.py", line 33, in async_setup_entry
homeassistant_app.1.x4d476o5470w@nuc01 | await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
homeassistant_app.1.x4d476o5470w@nuc01 |
homeassistant_app.1.x4d476o5470w@nuc01 | 2024-08-09 13:56:03.753 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry AmpliPi for amplipi
homeassistant_app.1.x4d476o5470w@nuc01 | Traceback (most recent call last):
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/config_entries.py", line 604, in async_setup
homeassistant_app.1.x4d476o5470w@nuc01 | result = await component.async_setup_entry(hass, self)
homeassistant_app.1.x4d476o5470w@nuc01 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
homeassistant_app.1.x4d476o5470w@nuc01 | File "/config/custom_components/amplipi/__init__.py", line 33, in async_setup_entry
homeassistant_app.1.x4d476o5470w@nuc01 | await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/config_entries.py", line 2085, in async_forward_entry_setups
homeassistant_app.1.x4d476o5470w@nuc01 | await integration.async_get_platforms(platforms)
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/loader.py", line 1177, in async_get_platforms
homeassistant_app.1.x4d476o5470w@nuc01 | import_future.result()
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/loader.py", line 1165, in async_get_platforms
homeassistant_app.1.x4d476o5470w@nuc01 | platforms.update(self._load_platforms(platform_names))
homeassistant_app.1.x4d476o5470w@nuc01 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/loader.py", line 1090, in _load_platforms
homeassistant_app.1.x4d476o5470w@nuc01 | platform_name: self._load_platform(platform_name)
homeassistant_app.1.x4d476o5470w@nuc01 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/loader.py", line 1264, in _load_platform
homeassistant_app.1.x4d476o5470w@nuc01 | cache[full_name] = self._import_platform(platform_name)
homeassistant_app.1.x4d476o5470w@nuc01 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/loader.py", line 1296, in _import_platform
homeassistant_app.1.x4d476o5470w@nuc01 | return importlib.import_module(f"{self.pkg_path}.{platform_name}")
homeassistant_app.1.x4d476o5470w@nuc01 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/src/homeassistant/homeassistant/util/loop.py", line 200, in protected_loop_func
homeassistant_app.1.x4d476o5470w@nuc01 | return func(*args, **kwargs)
homeassistant_app.1.x4d476o5470w@nuc01 | ^^^^^^^^^^^^^^^^^^^^^
homeassistant_app.1.x4d476o5470w@nuc01 | File "/usr/local/lib/python3.12/importlib/__init__.py", line 90, in import_module
homeassistant_app.1.x4d476o5470w@nuc01 | return _bootstrap._gcd_import(name[level:], package, level)
homeassistant_app.1.x4d476o5470w@nuc01 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen importlib._bootstrap_external>", line 995, in exec_module
homeassistant_app.1.x4d476o5470w@nuc01 | File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
homeassistant_app.1.x4d476o5470w@nuc01 | File "/config/custom_components/amplipi/media_player.py", line 20, in <module>
homeassistant_app.1.x4d476o5470w@nuc01 | from pyamplipi.models import ZoneUpdate, Source, SourceUpdate, GroupUpdate, Stream, Group, Zone, Announcement, \
homeassistant_app.1.x4d476o5470w@nuc01 | ImportError: cannot import name 'PlayMedia' from 'pyamplipi.models' (/usr/local/lib/python3.12/site-packages/pyamplipi/models.py)
Which version of the integration should we be using?!
Cheers,
Ben