NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

blocking start-up warning dialog "some executions were not released..."

Hi all,

Using the teststand API I'm occasionally getting the dialog: "some executions were not released the last time the teststand engine was destroyed" when I start up my application. 

For the most part I'm cleaning up everything correctly, and it doesn't come up very often, but sometimes it does. So I have two questions:

  • Is there a reason to actually care? What is the corrective action to take? 
  • Is there a way to block this dialog from ever appearing again, either by taking those corrective actions or by handling some sort of UI event?

Thanks

0 Kudos
Message 1 of 8
(3,025 Views)

Hi smithed,  sounds like you have just missed closing at least one API reference.  I guess it only happens occasionally for you as determined by if the code happens to branch into the section that doesn't close the reference.  I have never thought about blocking the dialog (not sure it is possible or a good idea), I have always searched for the missing Close Reference and added it.

Steve

0 Kudos
Message 2 of 8
(2,983 Views)

I think it mostly happens if I get into a hang and have to abort the program (or when lv crashes), but the cause is really besides the point. If I'm leaving a reference open, why is it telling me when I restart the program? What am I supposed to do about it then?

And more importantly, why is it a modal dialog telling my operator something that I don't even care about 😛 

 

The reason I ask is there seems to be a way to suppress most dialogs and replace with programmatic behavior, like callbacks for when an execution is still running and you try to shut down an engine, or station options for what to do. I'm trying to suppress all of the built-in dialogs and replace with software-defined responses, but this is one without a clear parameter or callback, so far as I can find.

0 Kudos
Message 3 of 8
(2,968 Views)

Leaving references open could lead to a memory growth issue and subsequent crash. 

 

What specific dialog boxes are you trying to suppress?

0 Kudos
Message 4 of 8
(2,944 Views)

 

@even-And wrote:

Leaving references open could lead to a memory growth issue and subsequent crash.  




Sure -- and knowing that at the end of execution (ie what the more informative reference leak dialog does), or in the form of a warning or a log message, potentially very useful.

 

However once the memory is leaked, the damage is done. From what I can tell (and what I was hoping to be corrected on) is that essentially teststand is providing a modal dialog saying, "before you continue, you must acknowledge that last time you ran teststand you were naughty and didn't shut down properly, but we won't tell you anything else about what you did wrong".. I don't find it particularly useful to be scolded by software 😛 

 

Now, if there is some action I can take, like programmatically resetting the teststand process in some way to clear out any leaks and give myself a fresh state...well that would be great. But I'm not sure how, or if its safe, to do so.

Edit: looks like this guy wanted to do the same thing, but the thread trailed off without a solution: https://forums.ni.com/t5/NI-TestStand/Some-question-about-programatically-resetting-an-engine/m-p/17...

 

even-And wrote:

What specific dialog boxes are you trying to suppress?

This one:

@smithed wrote:

Using the teststand API I'm occasionally getting the dialog: "some executions were not released the last time the teststand engine was destroyed" when I start up my application.  

 Its a one-button modal dialog (ie it just has "OK") and it appears to be generated when I call appmgr start.

 

0 Kudos
Message 5 of 8
(2,934 Views)

 If the message you are seeing is the one I'm thinking about, you can disable it in Configure>>Station Options>>Preferences>>Debug Options>>Report Object Leaks.

 

The message is basically saying "FYI: You have a bug in your code that you might want to find and fix."

Message 6 of 8
(2,916 Views)

Thanks. The description in the dialog sounds like it is specific to the shutdown leak dialog, but I haven't seen that one for a while so I've disabled it and will see if it works -- now just to reproduce the problem again 🙂

 

0 Kudos
Message 7 of 8
(2,890 Views)

I got the popup again today, not clear why. I have a fairly sequential test for my application that I always follow (load sequence, create execution, start run, single-step, poll, single-step, poll..etc... then shutdown). Out of say 10 runs today, 1 resulted in the dialog. I've reenabled the shutdown-leak-warning in hopes that I can figure out what the problem is, but...

 

On the subject of avoiding the dialog entirely, is it safe to completely reset the NI Teststand service? (or is that not where the engine 'lives'?) 

0 Kudos
Message 8 of 8
(2,867 Views)