LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
warren_scott

VIAnalyzer Error Cluster Wired also checks tunnels

Status: New

VI Analyzer has a "Error Cluster Wired" check, that does a great job of helping to find instances where you (accidentally) forgot to wire up the error out of a item on your block diagram.

Unfortunately, it only considers "Nodes" on the block diagram, and ignores tunnels through structures.

 

So you get problems like this:

droppedErrorLine.png

Where it won't notify you about not connecting the error tunnels (any flavor of tunnels, only shift registeres shown).

 

I'd like to see VIanalyzer Error Cluster Wired check to include ability to check for error tunnels (inside or outside terminal) in structures wired:

 

CheckTunnels.png

3 Comments
AristosQueue (NI)
NI Employee (retired)

That behavior is by design. Wiring to tunnels is designed to be an acceptable way to acknowledge "I am consciously dropping this error." That's why auto error handling does not fire on such terminals.

 

There's no technical problem I can see with adding it as an option, but if we added it, we would probably want to put comments on the dialog that explains why its default is turned off. And it will churn up a lot of noise if you run it over VIs that use the convention.

Darren
Proven Zealot

What if the test only checked unwired shift register output terminals, like the two given in the idea's screenshot?

warren_scott
Active Participant

Checking shift registers would be a start.  However it completely ignores case structures which can't have shift registers.

However, we have found several cases in our code where (after looking at the code) it was obvious that someone intended for the error line to be connected from a terminal on a structure to something else, but it was (for whatever reason) dropped.  We are hoping to use VIAnalyzer to help find these problems.

 

I can appreciate Stephen's comment above, and from that it would make sense to make sure it is configurable depending on the coding convention you use. 

 

Another thing that I considered was whether to look for an unwired error input terminal somewhere near the unwired "output" tunnel (near might give priority to similar vertical placement to the right).  This will not find the cases where you intended to wire the unwired error tunnel output to something way far away, but it would cut down dramatically the number of false hits for "wire error to structure tunnel to drop error"

 

Really, this needs an ability to tag a tunnel as "yes I intended to drop this error and not connect to anything" so that both VIAnalyzer can understand that was the intention, and more importantly that I, as the guy supporting someone else's code, can understand that really was the intention.