[Bug] module 'hikaxpro' has no attribute 'USER_LEVEL_ADMIN_OPERATOR'
0dragosh opened this issue · 5 comments
0dragosh commented
On the latest v2.3.0 I get this error when setting up the integration.
ERROR (MainThread) [homeassistant.config_entries] Error setting up entry Hikvision_axpro_$host for hiTraceback (most recent call last): File
"/usr/local/lib/python3.12/site-packages/homeassistant/config_entries.py", line 594, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/hikvision_axpro/__init__.py", line 77, in async_setup_entry axpro = hikaxpro.HikAxPro(host, username, password, user_level=hikaxpro.USER_LEVEL_ADMIN_OPERATOR) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 'hikaxpro' has no attribute 'USER_LEVEL_ADMIN_OPERATOR'
petrleocompel commented
It seems like your dependency did not update ...
Or is this fresh install?
0dragosh commented
@petrleocompel thanks for the fast reply!
That was indeed the issue. I upgraded the hikaxpro
pip package and all is well now.
petrleocompel commented
Do you have a standard setup? Using hacs or it is something custom??
0dragosh commented
I have a very “non-standard” setup, but I am using HACS. I am running rootless HASS in kubernetes with a CiliumNetworkPolicy whitelisting ingress/egress (I think that’s what caused the issue with the upgrade) with this image ghcr.io/onedr0p/home-assistant:2024.10.4
from here.
petrleocompel commented
Understand. Just wanted to know if it affects standard users. So no.