On some OPC-Servers (in my case FlowChief OPC) if using a group in the read() request the first read ends with a ValueError "can't format dates this early". A second read() on the same group is then fine and returns useful values.
Not that I used the 1.2.0 code-base but also looked up the situation in 1.3.1 code (see later comments on that)
The ValueError exception comes from the following statement in iread()
timestamp = str(tag_time[tag]) --- line 560
I debugged that in ipython and found that the reason for that is that the reported tag_time has the following value <pytime:01 01="" 1601="" 00:00:00="" am=""> (probably just an non initialized timestamp default of that OPC-server)
When the str() method is applied on that PyTime object the exception is raised.
You can look this up in https://github.com/kovidgoyal/pywin32/blob/master/win32/src/PyTime.cpp (line 174).
I am not an expert in PyTime cannot tell why this kind of exception is raised when the year is < 1900.</pytime:01>
In the 1.3.1 code-base this ValueError exception is captured and a None is returned as timestamp.
This is somehow OK an I can on application level then handle that situation as a special case.
I found an other way that allows the system to handle the situation in a more normal way:
See the attached patch file that proposes a patch for the 1.3.1 code-base where also variable values of type pywintypes.TimeType could now be using dates earlier than year 1900.
Best
Georges