Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
opcua-asyncio
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nikola Balog
opcua-asyncio
Commits
8a36cf02
Commit
8a36cf02
authored
Jul 23, 2020
by
oroulet
Committed by
oroulet
Jul 30, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ignore Uniion types sinceI have no ideas what they are yet
parent
98eb074d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
asyncua/common/structures104.py
asyncua/common/structures104.py
+6
-2
examples/client_play_with_type_definition.py
examples/client_play_with_type_definition.py
+0
-1
No files found.
asyncua/common/structures104.py
View file @
8a36cf02
...
...
@@ -178,14 +178,18 @@ async def load_data_type_definitions(server, base_node=None):
dtypes = []
await _recursive_parse(server, base_node, dtypes)
for dts in dtypes:
env = await _generate_object(dts.name, dts.sdef)
ua.register_extension_object(dts.name, dts.encoding_id, env[dts.name], dts.desc.NodeId)
try:
env = await _generate_object(dts.name, dts.sdef)
ua.register_extension_object(dts.name, dts.encoding_id, env[dts.name], dts.desc.NodeId)
except NotImplementedError:
logger.exception("Structure type %s not implemented", dts.sdef)
async def _read_data_type_definition(server, desc):
if desc.BrowseName.Name == "FilterOperand":
#FIXME: find out why that one is not in ua namespace...
return None
# FIXME: this is fishy, we may have same name in different Namespaces
if hasattr(ua, desc.BrowseName.Name):
return None
logger.warning("Registring data type %s %s", desc.NodeId, desc.BrowseName)
...
...
examples/client_play_with_type_definition.py
View file @
8a36cf02
...
...
@@ -17,7 +17,6 @@ async def main():
#client.secure_channel_timeout=8000
async
with
client
:
dt
=
await
client
.
nodes
.
base_structure_type
.
get_child
(
"AddNodesItem"
)
code
=
await
make_structure_code
(
dt
)
df
=
await
dt
.
read_data_type_definition
()
await
client
.
load_data_type_definitions
()
edt
=
await
client
.
nodes
.
enum_data_type
.
get_child
(
"ApplicationType"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment