Open ondrejnovakcvut opened 2 years ago
that dict history stuff was more a code example that something really usefull. fix welcome. It should not be really hard
does values without timestamps make sense in a history?
does values without timestamps make sense in a history?
it probably doesn't, but it's handy for debugging
that dict history stuff was more a code example that something really usefull. fix welcome. It should not be really hard
I'll take a look on it
Describe the bug
When running the server with
HistoryDict
enabled and using a client that does not set SourceTimestamp (tested with UA Expert), functionread_raw_history
fails withTypeError: '<=' not supported between instances of 'datetime.datetime' and 'NoneType'
when it tries to filter out the values out of range given by function parametersstarttime
andendtime
.To Reproduce
HistoryDict
enabled (server.iserver.history_manager.set_storage(HistoryDict())
)myvar.set_writable()
) and enable its historization (server.historize_node_data_change(myvar, period=None, count=100)
)SourceTimestamp
server.read_raw_history(numvalues=10)
Expected behavior
I'm not sure what the function should do with records having
SourceTimestamp
equal toNone
.HistorySQLite
seems to ignore these values (the list only contains values havingSourceTimestamp
set). Maybe there could be a parameter toread_raw_history
that would tell the function to include these values.Version
Python-Version: 3.9 opcua-asyncio Version): asyncua==0.9.92 from pypi