Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.
First time visiting? Here are some places to start:- Looking for a certain topic? Check out the categories filter or use Search (upper right).
- Need support? Ask a question to our Community Support category.
- Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
- Be respectful, on topic and if you see a problem, Flag it.
If you would like to contact our Community Manager personally, feel free to send a private message or an email.
What happens with patterns and preconditions?
S1mon
Member Posts: 2,983 PRO
I'm noticing some behavior with @Evan_Reese's 3D Point where a pattern of points silently creates no point when "Location on curve" goes slightly over 1.0, and then any feature (say a plane) which is dependent on that point does weird stuff. Normally if you are entering a value into the feature, the precondition limits the value to [0...1.0]. It seems like when that value is set with a varying "linear" pattern, that the precondition doesn't do anything. (I'm just using the pattern to iterate through the features).
annotation { "Name" : "Location on curve", "UIHint" : UIHint.MATCH_LAST_ARRAY_ITEM } isReal(vertex.curveParameter, { (unitless) : [0, .5, 1] } as RealBoundSpec);
I checked with a simple variable and a single point, and increasing from 1.0 to 1.1 causes the 3D Point feature to fail, but in a pattern, nothing fails, it just has very unexpected downstream behavior.
Is there some reason why patterns don't trigger the precondition tests? Do features need extra bounds checking on inputs to avoid this kind of thing?
Here's a really simple example:
Range set to 1, and the pattern works as expected
Here it is with the range set to 1.01, and the last point silently fails (although the FeatureScript notices show errors), but the plane does something completely unexpected.
Is there some reason why patterns don't trigger the precondition tests? Do features need extra bounds checking on inputs to avoid this kind of thing?
Here's a really simple example:
Range set to 1, and the pattern works as expected
Here it is with the range set to 1.01, and the last point silently fails (although the FeatureScript notices show errors), but the plane does something completely unexpected.
0
Answers