-
Couldn't load subscription status.
- Fork 413
Open
Description
Hi Everyone,
I want to use asyncua to connect to the Microsoft OPC PLC demo server via docker.
I have this code which writes to a custom node I have developed:
import asyncio
from asyncua import Client, ua
URL = "opc.tcp://localhost:4840"
async def main():
print(f"Connecting to {URL} ...")
async with Client(url=URL) as client:
print("CONNECTED!")
if __name__ == "__main__":
try:
asyncio.run(main())
except Exception as e:
print(f"An error occurred: {e}")
On v1.1.6 this works:
Connecting to opc.tcp://localhost:4840 ...
CONNECTED!
But on v1.1.8 it fails:
Connecting to opc.tcp://localhost:4840 ...
ServiceFault (BadServerUriInvalid, diagnostics: DiagnosticInfo(SymbolicId=None, NamespaceURI=None, Locale=None, LocalizedText=None, AdditionalInfo=None, InnerStatusCode=None, InnerDiagnosticInfo=None)) from server received in response to CreateSessionRequest
An error occurred: The ServerUri is not a valid URI.(BadServerUriInvalid)
I suspect maybe there has been some subtle change in validation that affects my use case? I'm also happy to change how I use the client, but I've been banging my head for some time and can't figure it out.
Metadata
Metadata
Assignees
Labels
No labels