-
Notifications
You must be signed in to change notification settings - Fork 364
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
get_path created BrowsePath finds not match via tranlate_browsepaths #1706
Comments
A way to get all paths of a node would be nice too |
as far as i know not part of OPC UA Spec.! For TranslateBrowsePaths the client needs to know the path to the node, from which the client wants the nodeid from! |
Yeah that's what I want to do but the From my understanding the |
the only difference is: |
No this does not affect the The node in question is referenced twice (as shown in the screenshot on the right side). |
get_path just uses the first reference see: opcua-asyncio/asyncua/common/node.py Line 538 in 1343fa7
|
browsename is correctly formatted: opcua-asyncio/asyncua/ua/uatypes.py Line 679 in 1343fa7
and the relative path implementation looks right on the first look |
Yeah I guess so but this seems counterintuitive since I would assume that I could directly put the path from the get_path function (transformed into a valid string) into the translate_path function and would get the same node back |
but both paths are valid! |
But the second one does not work. You can run the code yourself and connect to the server yourself (via gui), the opcua server in the example is public. I've extended the example code to include the just read path via
|
"BadNoMatch" is a response from Server! We just use the first hierarchical Reference and follow them up ("inverse" direction)... it does not matter which you chose because they point to the same NodeId/Node... |
Yes I understand that the error is a response from the server. I would prefer that the get_path would return all paths but that is my issue since that functionality is not a part of the spec. But I still don't understand why the The code in this comment creates a valid path that the translate service on the server somehow can't resolve. |
This is a BUG REPORT for issues in the existing code.
Describe the bug
I'm using the
get_path(as_string=True)
function from the node class.The function chooses a 'wrong' path so that the
translate_browsepaths()
function generates the status code "BadNoMatch"The Prosys Browser can also export a browse path (right click on node) which does find a match via the
translate_browsepaths()
function.The node 'exists' in both paths but only the path from prosys works.
To Reproduce
Steps to reproduce the behavior incl code:
The browse path that was exported from Prosys works:
/Objects/3:Simulation/3:Counter/2:Signal/4:Direction
Expected behavior
The function
get_path(as_string=True)
should generate a path that works with thetranslate_browsepaths()
function.Screenshots
Version
Python-Version:3.11.5
opcua-asyncio Version (e.g. master branch, 0.9):
The text was updated successfully, but these errors were encountered: