-
Notifications
You must be signed in to change notification settings - Fork 907
Check base_of_exclude attribute on Primitive
#1749
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov Report
@@ Coverage Diff @@
## main #1749 +/- ##
==========================================
+ Coverage 98.63% 98.71% +0.07%
==========================================
Files 138 138
Lines 15373 15377 +4
==========================================
+ Hits 15163 15179 +16
+ Misses 210 198 -12
Continue to review full report at Codecov.
|
| test_primitive.stack_on = [] | ||
| child.primitive.base_of = [] | ||
| child.primitive.base_of_exclude = [test_primitive] | ||
| assert not check_stacking(test_primitive(), [child]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if stack_on and base_of are both set to []. check_stacking will return False even if test_primitive is not in base_of_exclude
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh okay, interesting. I changed stack_on and base_of to None so they can return True. It kind of seems like whether None or [] the value should be the same.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think None means no whitelist while [] means an empty whitelist, so nothing allowed
…s into base-of-exclude
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Currently, we check the
base_of_excludeattribute on Feature classes instead of Primitive classes which raises an error.Example
Related to #1739