Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pai not connecting to IP module after upgrade to 22.04 and python 3.10.6 #369

Closed
britsmarius opened this issue Jun 12, 2023 · 12 comments
Closed
Labels
question Further information is requested

Comments

@britsmarius
Copy link

I am getting the following after updating to Linux 22.04 and python 3.10.6

I am apple to access the IP150 via web and ping it, the problem seems after authentication.

2023-06-12 22:30:40,701 - INFO - PAI.paradox.connections.connection - Connection established
2023-06-12 22:30:40,701 - INFO - PAI.paradox.connections.ip.commands - Authenticating with IP Module
2023-06-12 22:30:40,702 - ERROR - PAI.paradox.connections.ip.connection - Unhandled exception while connecting (try 3/3)
Traceback (most recent call last):
File "/home/marius/pai/paradox/connections/ip/connection.py", line 30, in connect
await self._try_connect()
File "/home/marius/pai/paradox/connections/ip/connection.py", line 121, in _try_connect
await IPModuleConnectCommand(self).execute()
File "/home/marius/pai/paradox/connections/ip/commands.py", line 16, in execute
await self._authenticate_to_ip_module()
File "/home/marius/pai/paradox/connections/ip/commands.py", line 104, in _authenticate_to_ip_module
msg = IPMessageRequest.build(
File "/home/marius/.local/lib/python3.10/site-packages/construct/core.py", line 356, in build
self.build_stream(obj, stream, **contextkw)
File "/home/marius/.local/lib/python3.10/site-packages/construct/core.py", line 368, in build_stream
self._build(obj, stream, context, "(building)")
File "/home/marius/.local/lib/python3.10/site-packages/construct/core.py", line 2024, in _build
buildret = sc._build(subobj, stream, context, path)
File "/home/marius/.local/lib/python3.10/site-packages/construct/core.py", line 2493, in _build
return self.subcon._build(obj, stream, context, path)
File "/home/marius/.local/lib/python3.10/site-packages/construct/core.py", line 2761, in _build
return self.subcon._build(obj, stream, context, path)
File "/home/marius/.local/lib/python3.10/site-packages/construct/core.py", line 3621, in _build
return sc._build(obj, stream, context, path)
File "/home/marius/.local/lib/python3.10/site-packages/construct/core.py", line 722, in _build
obj2 = self._encode(obj, context, path)
File "/home/marius/pai/paradox/connections/ip/parsers.py", line 70, in encode
return encrypt(obj, context.
.password)
File "/home/marius/pai/paradox/lib/crypto.py", line 233, in encrypt
rk = _keygen(key)
File "/home/marius/pai/paradox/lib/utils.py", line 111, in call
if not isinstance(args, collections.Hashable):
AttributeError: module 'collections' has no attribute 'Hashable'
2023-06-12 22:30:40,704 - ERROR - PAI.paradox.paradox - Failed to connect to interface
2023-06-12 22:30:40,704 - ERROR - PAI - Unable to connect to alarm
^C2023-06-12 22:30:41,123 - INFO - PAI - Captured signal SIGTERM. Exiting
2023-06-12 22:30:41,123 - INFO - PAI.paradox.paradox - Disconnecting from the Alarm Panel
2023-06-12 22:30:41,124 - INFO - PAI.paradox.paradox - Clean Session
2023-06-12 22:30:41,124 - INFO - PAI.paradox.interfaces.interface_manager - Stopping all interfaces
2023-06-12 22:30:41,124 - INFO - PAI.paradox.interfaces.interface_manager - Stopping BasicMQTTInterface
2023-06-12 22:30:41,126 - INFO - PAI.paradox.interfaces.mqtt.core - MQTT Broker Disconnected
2023-06-12 22:30:41,127 - INFO - PAI.paradox.interfaces.mqtt.core - MQTT loop stopped
2023-06-12 22:30:41,127 - INFO - PAI - Good bye!
2023-06-12 22:30:41,129 - ERROR - PAI.paradox.connections.protocols - Connection was closed: None
2023-06-12 22:30:41,130 - ERROR - PAI.paradox.connections.connection - Connection was lost
2023-06-12 22:30:41,130 - ERROR - PAI.paradox.connections.protocols - Connection was closed: None
2023-06-12 22:30:41,130 - ERROR - PAI.paradox.connections.connection - Connection was lost
2023-06-12 22:30:41,130 - ERROR - PAI.paradox.connections.protocols - Connection was closed: None
2023-06-12 22:30:41,131 - ERROR - PAI.paradox.connections.connection - Connection was lost
2023-06-12 22:31:10,187 - ERROR - PAI.paradox.connections.protocols - Connection was closed: None
2023-06-12 22:31:10,187 - ERROR - PAI.paradox.connections.connection - Connection was lost
2023-06-12 22:31:10,187 - ERROR - PAI.paradox.connections.protocols - Connection was closed: None
2023-06-12 22:31:10,188 - ERROR - PAI.paradox.connections.connection - Connection was lost

@britsmarius britsmarius added the question Further information is requested label Jun 12, 2023
@yozik04
Copy link
Collaborator

yozik04 commented Jun 13, 2023

Please install dependencies properly. Refer to the wiki.

@britsmarius
Copy link
Author

i will look into that again but this was working before the update which I wish I never did

@yozik04
Copy link
Collaborator

yozik04 commented Jun 13, 2023

I suspect 'construct' dependency is too new. I did not had a chance to change the code so it would support newest version.

@britsmarius
Copy link
Author

Thank you for your input just want to make sure there is then nothing I can do at the moment with this

@yozik04
Copy link
Collaborator

yozik04 commented Jun 13, 2023

Why nothing. Just downgrade it to the supported version.

@britsmarius
Copy link
Author

If possible please advise on how to do this in Ubuntu 22.04

@yozik04
Copy link
Collaborator

yozik04 commented Jun 14, 2023

https://pypi.org/project/paradox-alarm-interface/

Did you install from pypi?

@britsmarius
Copy link
Author

britsmarius commented Jun 14, 2023 via email

@yozik04
Copy link
Collaborator

yozik04 commented Jun 14, 2023

Manual requires understanding what you do. :)

@britsmarius
Copy link
Author

I am going the docker route but I think I am missing something with the pai.conf file do you remove the # or only update the fields without removing this as it keeps trying to connect via serial although I have said IP

@yozik04
Copy link
Collaborator

yozik04 commented Jun 14, 2023

Removing # is called "uncommenting". If you need to change a setting. You uncomment and change the value. Default values are always commented out.

@britsmarius
Copy link
Author

britsmarius commented Jun 14, 2023 via email

@ParadoxAlarmInterface ParadoxAlarmInterface locked and limited conversation to collaborators Jun 14, 2023
@yozik04 yozik04 converted this issue into discussion #371 Jun 14, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants