How to interpret a FeatureScript Notice
peter_morris
Member Posts: 43 ✭✭
While developing a FeatureScript Feature I often see notices of the sort shown below. In this example the number 75.5 appears next to the text 'myGear Feature Studio', but it doesn't appear to correlate with anything in the actual script nor have any of the other examples I've seen. For info, myGear is the feature I'm designing and 'addendum' I know is defined but not currently used, so I understand what its telling me, I just don't understand the 75.5 bit. Can anyone explain what it does mean and perhaps where its documented - I'm rather hoping that it will lead to more effective debugging than is possible with 'debug'. Many thanks.
<br><div class="Quote">Variable addendum set but not used<br><pre class="CodeBlock"><code>75.5 myGear Feature Studio
0
Best Answers
-
Below each notice message, i.e. "Variable addendum set but not used" in this case, is a collapsible stack trace for where the notice is coming from. I'm betting that your Feature Studio tab name is "myGear Feature Studio" and the starting location of the notice in your code is on line 75, column 5.
If you click on one of the lines in the stack trace (in your case your stack only has one line), it should take you to the specified line and column in the specified Feature Studio.
What is strange here is that you're seeing "75.5" rather than "75:5" which is our intended designation for "line:column". Does it show up too faintly on your screen? Perhaps we need to emphasize it just a touch?5 -
Peter,
We do intend to continuously improve the FeatureScript debugging experience, but building a full debugger is still some time off.Ilya Baran \ VP, Architecture and FeatureScript \ Onshape Inc6
Answers
-
Below each notice message, i.e. "Variable addendum set but not used" in this case, is a collapsible stack trace for where the notice is coming from. I'm betting that your Feature Studio tab name is "myGear Feature Studio" and the starting location of the notice in your code is on line 75, column 5.
If you click on one of the lines in the stack trace (in your case your stack only has one line), it should take you to the specified line and column in the specified Feature Studio.
What is strange here is that you're seeing "75.5" rather than "75:5" which is our intended designation for "line:column". Does it show up too faintly on your screen? Perhaps we need to emphasize it just a touch?5 -
Kori, many thanks for this - It was 75:5, I just hadnt noticed. Slightly unhelpfully that location is simply the start of the 'what does it do' section so didn't really point to the location that caused the error.
It might help if there was more documentation about how to use Debug - I've now discovered I can place simple text in front of the variable so that when reading a number of debug() statements it is clear how it relates to the code..
Is there any change you'll be developing a better debug environment? (though I realise much of the challenge is my lack of familiarity with the structure and grammar!)
0 -
Peter,
We do intend to continuously improve the FeatureScript debugging experience, but building a full debugger is still some time off.Ilya Baran \ VP, Architecture and FeatureScript \ Onshape Inc6


