06-09-2021 04:54 AM
This seems to be related to https://forums.ni.com/t5/NI-TestStand/Some-Executions-Are-Not-Terminated-by-Using-Terminate-All-in/m...
Here I am using a simplified sequence. It runs four sockets using batch model. A sub-sequence call uses serial synchronization. When socket 1 comes to execution, it sends Engine.TerminateAll(). All sockets read the terminating status as first step of Main block using ActiveX call RunState.Execution.GetStates and record it to results .
Sometimes Sockets 2 and/or 3 do report terminating status as 2 (=Terminating), but still run all the steps in Main block.
I used TS 2017 SP1. I also had similar behavior in TestStand 2020, but could repeat it using this particular sequence. Sometimes I need to repeat the test 5 - 20 times, before this behavior happens. Also, if Windows is otherwise busy, e.g. updating, it seems that this behavior does not happen.
It seems, that if synchronization steps are used instead of synchronization of sequence calls, this does not happen, but haven't totally confirm it, since I do have an automated system to test this hundreds of times.
I will attach an example sequence and a report showing this behavior in Socket 2 results. (I am not sure why results are not in numerical order, but that is not an issue to me).
To me, it seems that either there is a bug in TestStand or Terminating is just a suggestion and not pre-emptive deterministic thing or that I have understood something wrong.
06-10-2021 01:11 PM
Thanks for the report. It took a while, but I was finally able to reproduce this. It is on my list to investigate further soon.
10-21-2021 11:02 AM
I made a bug report about this, and they say, it's going to fixed in a future release.
NI was not able to replicate this, if batch synchronization steps were used instead of setting synchronization in a sequence call. So that works as a temporary fix.