Skip to content
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

How to change the timeout variable? #103

Open
Dardanos-Aeolus opened this issue Feb 7, 2025 · 0 comments
Open

How to change the timeout variable? #103

Dardanos-Aeolus opened this issue Feb 7, 2025 · 0 comments

Comments

@Dardanos-Aeolus
Copy link

When I am connected to a remote OPC-UA server via VPN,
I am able to connect directly with the opcua-asyncio library:
This work perfectly:

uasubscribe -u opc.tcp://192.168.180.210:4840 --timeout 30000 -n ns=4;i=63

However this does not work:

uasubscribe -u opc.tcp://192.168.180.210:4840 -n ns=4;i=63

Error:

    return self._uasocket.connect_socket(host, port)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\...\Python312\site-packages\opcua\client\ua_client.py", line 155, in connect_socket
    sock = socket.create_connection((host, port), timeout=self.timeout)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Program Files\...\Lib\socket.py", line 865, in create_connection
    raise exceptions[0]
  File "C:\Program Files\..\Lib\socket.py", line 850, in create_connection
    sock.connect(sa)
TimeoutError: timed out

This leads me to the conclusion that in my particular case the --timeout flag is crucial to use.

Question:
How do I enable --timeout with the GUI client?
At the moment I only get a TimeoutError when trying to connect with the GUI.

I tried to search for timeout in the source-code and dirty hard code it to a different value, but it didn't work.

Thanks for your help in advance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant