-
Notifications
You must be signed in to change notification settings - Fork 3
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
Change how we search for attributes #91
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #91 +/- ##
==========================================
+ Coverage 87.60% 87.75% +0.14%
==========================================
Files 28 28
Lines 1170 1184 +14
==========================================
+ Hits 1025 1039 +14
Misses 145 145 ☔ View full report in Codecov by Sentry. |
7e66f35
to
a02b447
Compare
a02b447
to
8a0c003
Compare
779073f
to
0edc27c
Compare
Will make this a draft while I write docs and make branches on eiger and odin. |
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 it might be nicer to add these attributes to an _attributes
member dict in __init__
rather than have a getter and then manually adding them to the member attribute on access. All the messy logic of searching through dir()
, checking for clashes and filtering of root_attribute
could be done in one place (_bind_attrs
) instead of in Mapping
.
It also occurs to me that we aren't gaining anything by making root_attribute
a property, because we still have to check for "root_attribute"
anyway. So, maybe it could just be a class member on SubController
with default None
.
Thoughts?
I agree this would definitely be nicer, still not containing any of the attributes defined globally in the class though.
Would also probably be nicer. We would still have to filter it out when searching through all the attributes on the |
da21c22
to
8110e2e
Compare
8110e2e
to
6489767
Compare
6756c68
to
4d09743
Compare
4d09743
to
817d7da
Compare
817d7da
to
5243d6a
Compare
`root_attribute` is parsed on `register_sub_controller`
5243d6a
to
f45ac5c
Compare
Closes #89