-
-
Notifications
You must be signed in to change notification settings - Fork 65
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
Well _actually #112
Comments
Nice of you to say so! |
I've definitely felt it's a bit awkward to be cramming everything into the flat class namespace, when really only the input methods need to live there, and the outputs and states all want to be private. I'm curious how you'd structure such an |
I think that #137 changes the structure so that it is much easier to avoid this sort of naming. There's still some level of duplication, you've got input protocol methods and you've got behavior implementation functions, but they can just be named the same thing now since they don't need to exist in the same namespace, so you don't need to mangle them with conventions like " |
Hey Glyph,
I'm a big fan of this library. I'm noticing that there's a certain pattern which makes me wonder about an API, and I'm curious to hear your thoughts.
The docs have an example like this:
which uses the
_actually_send_message
method. It reminds me a bit of marshmallow's pattern offield.serialize()
callingfield._serialize()
and similar inheritance-oriented APIs. The common_actually_*
naming convention makes me wonder if there should be a real namespace for these implementationsor
mm.impl.send_mesage
.I'm interested if you've had this feeling or how you've dealt with the proliferation of
_actually
methods.Cheers.
The text was updated successfully, but these errors were encountered: