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
a847e93b
Commit
a847e93b
authored
Jul 01, 2024
by
Olivier
Committed by
oroulet
Jul 02, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make new ruff version happy
parent
bf9ac444
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
4 deletions
+4
-4
asyncua/ua/uatypes.py
asyncua/ua/uatypes.py
+1
-1
tests/test_common.py
tests/test_common.py
+1
-1
tests/test_subscriptions.py
tests/test_subscriptions.py
+1
-1
tests/test_unit.py
tests/test_unit.py
+1
-1
No files found.
asyncua/ua/uatypes.py
View file @
a847e93b
...
@@ -57,7 +57,7 @@ def type_is_union(uatype):
...
@@ -57,7 +57,7 @@ def type_is_union(uatype):
def
type_is_list
(
uatype
):
def
type_is_list
(
uatype
):
return
get_origin
(
uatype
)
==
list
return
get_origin
(
uatype
)
is
list
def
type_allow_subclass
(
uatype
):
def
type_allow_subclass
(
uatype
):
...
...
tests/test_common.py
View file @
a847e93b
...
@@ -2059,7 +2059,7 @@ async def test_alias(opc):
...
@@ -2059,7 +2059,7 @@ async def test_alias(opc):
],
],
)
)
await
opc
.
opc
.
load_data_type_definitions
()
await
opc
.
opc
.
load_data_type_definitions
()
assert
type
(
ua
.
MyString
())
==
ua
.
String
assert
type
(
ua
.
MyString
())
is
ua
.
String
var
=
await
opc
.
opc
.
nodes
.
objects
.
add_variable
(
var
=
await
opc
.
opc
.
nodes
.
objects
.
add_variable
(
idx
,
"AliasedString"
,
"1234"
,
datatype
=
dt_str
.
nodeid
idx
,
"AliasedString"
,
"1234"
,
datatype
=
dt_str
.
nodeid
)
)
...
...
tests/test_subscriptions.py
View file @
a847e93b
...
@@ -500,7 +500,7 @@ async def test_modify_monitored_item(opc):
...
@@ -500,7 +500,7 @@ async def test_modify_monitored_item(opc):
results
=
await
sub
.
modify_monitored_item
(
handle
,
2000
)
results
=
await
sub
.
modify_monitored_item
(
handle
,
2000
)
assert
results
assert
results
assert
len
(
results
)
==
1
assert
len
(
results
)
==
1
assert
type
(
results
[
0
])
==
ua
.
MonitoredItemModifyResult
assert
type
(
results
[
0
])
is
ua
.
MonitoredItemModifyResult
assert
results
[
0
].
RevisedSamplingInterval
==
2000
assert
results
[
0
].
RevisedSamplingInterval
==
2000
await
sub
.
unsubscribe
(
handle
)
await
sub
.
unsubscribe
(
handle
)
await
sub
.
delete
()
await
sub
.
delete
()
...
...
tests/test_unit.py
View file @
a847e93b
...
@@ -633,7 +633,7 @@ def test_qualified_name():
...
@@ -633,7 +633,7 @@ def test_qualified_name():
def
test_datavalue
():
def
test_datavalue
():
dv
=
ua
.
DataValue
(
123
,
SourceTimestamp
=
datetime
.
now
(
timezone
.
utc
))
dv
=
ua
.
DataValue
(
123
,
SourceTimestamp
=
datetime
.
now
(
timezone
.
utc
))
assert
dv
.
Value
==
ua
.
Variant
(
123
)
assert
dv
.
Value
==
ua
.
Variant
(
123
)
assert
type
(
dv
.
Value
)
==
ua
.
Variant
assert
type
(
dv
.
Value
)
is
ua
.
Variant
dv
=
ua
.
DataValue
(
'abc'
,
SourceTimestamp
=
datetime
.
now
(
timezone
.
utc
))
dv
=
ua
.
DataValue
(
'abc'
,
SourceTimestamp
=
datetime
.
now
(
timezone
.
utc
))
assert
dv
.
Value
==
ua
.
Variant
(
'abc'
)
assert
dv
.
Value
==
ua
.
Variant
(
'abc'
)
assert
isinstance
(
dv
.
SourceTimestamp
,
datetime
)
assert
isinstance
(
dv
.
SourceTimestamp
,
datetime
)
...
...
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