NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

TestStand Automatically Closes After Long‑Duration Execution (4–5 Hours) – “Object Reference Not Set…” Error

Hello,

I am facing an issue while running long‑duration automated tests in TestStand (2017).

After around 4–5 hours of execution, TestStand shows two popup errors, and immediately after these popups the TestStand application closes automatically and the test run stops.

The popups are:

  1. “Object reference not set to an instance of an object.”
  2. “Exception has been thrown by the target of an invocation.”

Once these two errors appear, TestStand shuts down completely.

I want to understand:

  • What could cause these two errors during long test execution?
  • Is this related to memory leak, custom step module, sequence callbacks, or report generation?
  • How can I debug or capture more detailed logs before TestStand closes?
  • Any recommended fixes or best practices for long (multi‑hour) test runs in TestStand 2017?

And the Test stop/ pop-up time is not fixed to any specific sub-sequence. Its comes randomly.  

 

Any guidance or troubleshooting steps will be very helpful.

 

Also attached the pop-up screenshots.

 

Thank you.

Download All
0 Kudos
Message 1 of 5
(663 Views)

Helping you is difficult with this small amount of context!

 

When does this happen? MainSequence? ProcessModel?

Are you able to suspend the execution to further diagnose this?

0 Kudos
Message 2 of 5
(656 Views)

The pop-up appears randomly in the Main sequence execution. So its getting difficult to set a breakpoint on any specific test.

How to debug to trace back to the location because which this exception is occurring?

Does TestStandd saves any context before this occurs so that I can get more detail information

0 Kudos
Message 3 of 5
(641 Views)

If TS crahses like this, you usually get warnings on restart about leaking object references.

Does ths happen during Dev or Deployment?

0 Kudos
Message 4 of 5
(632 Views)

Never faced such scenario during the development phase. 

0 Kudos
Message 5 of 5
(624 Views)